* Fix assertion descriptions
Move return statement to the end of define()
* ospec: Fix assertion definitions
* Fix typo in assertion
* Add test for descriptions being returned on fail
* Reference result instead of self in returned description method
* Fix style errors
- Correct docs generation to always fetch its dependency
- Don't try to close a handle that's already been closed by other methods
- Allow the release script to actually be testable.
* Actually return the check from `maybeSetContentEditable`
Lots of code paths relied on it being a boolean. When I created the
abstraction, I apparently forgot to make sure it returned the result.
* Don't forget to copy instance state over
* Update changelog [skip ci]
* Fix changelog issue [skip ci]
- Lot of people couldn't migrate to v1 and plan to reevaluate when v2 is
released.
- It's "npm" not "NPM". It doesn't stand for anything, and it never
has - it was initially chosen simply because it was easy to type.
It has a lot of unofficial backronyms with "Node Package Manager"
being one of the most common ones, but it's never officially stood
for anything as an acronym *or* initialism.
- Fixed a few errors in the change log, like non-breaking changes being
included in the "Breaking Changes" section and an inaccuracy in the
summary of a particular change.
- Fixed RawGit URLs to point to GitHack, which is a lighter proxy that
offloads caching to Cloudflare instead of also implementing it itself.
(It also just uses nginx for all the important server logic, so it
scales better.)
- Add a few more v0.2 references as appropriate
* Fix#2414, address part of #1687
Also cleared the CSS up to be a lot more readable instead of smooshed
into a single line.
* Redo the testing docs page
- Addresses another part of #1687
- Also, fix a few linter issues in the ospec binary
* Add note about third-party cookies, tweak a line
* Make the JSX comparison much more meaningful
And let the code speak for itself. Don't fuel the flame wars any more
than what they've already become. We should be *unopinionated*, and so
I've updated those docs to remove the existing opinion.
* Remove a bunch of outdated ES6 references
* Remove the CSS page
* Fix a copy/paste fail
Also, fix some incorrect tests.
* Clarify how routes are diffed, improve key + route resolver docs
- Add some missing links to route resolvers and single-child keyed
fragments, clarify usage around them.
- Drive-by: remove a redundant sentence that itself was missing a
period.
* Actually test for propagation and preventDefault
Previously, the mocks were both junk and inaccurate. No wonder my tests
were silently failing - they were wrong and not obviously wrong.
* Recast the router API to be a lot more intuitive.
Fixes#2387Fixes#2072
Fixes quite a few issues reported on Gitter.
For `m.route.Link`:
- More intuitive
- More accessible
- More ergonomic
- It can be disabled
- It can be cancelled
- It can be changed
- Oh, and you can use it isomorphically.
For `m.route.prefix`
- You can *read* it.
- You can write to it, of course.
- It's literally just setting a property.
For the router itself (and the rest of Mithril):
- You can now `require("mithril")` and all its submodules without a DOM
at all. There is a catch: you can't instantiate any routes, you can't
mount anything, and you can't invoke `m.render` in any capacity. You
can only use `m.route.Link`, `m.route.prefix`, hyperscript stuff, and
`mithril/stream`, and you can use `m.request` with `background: true`
if you use a global XHR polyfill. (You can't use `m.request` without
`background: true` except with a DOM to redraw with.) The goal here is
to try to get out of the way for simple testing and to defer the
inevitable `TypeError`s for the relevant DOM methods to runtime.
The factory requires no arguments, and in terms of globals, you can
just figure out based on what errors are thrown what globals to
define. Their values don't matter - they just need to be set to
*something*, even if it's just `null` or `undefined`, before Mithril
executes.
Had to make quite a few other changes throughout the docs and tests to
update them accordingly. Oh, and that massive router overhaul enabled me
to do all this.
Also, slip in a few drive-by fixes to the mocks so they're a little
easier to work with and can accept more URLs. This was required for a
few of the tests.
* Update changelog + numbers, add forgotten bundle option
* Add PR numbers to changelog [skip ci]
* Allow continuing to the next match by returning `false`.
* Update numbers again