-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add type-hinting for reserved properties #79
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Before, with patch as an attribute of h, patch was not available to be called recursively. Fixed that, and also use module.exports rather than es6 module export syntax, to make it independent of babel-use
Fix scope availability of patch function
- Fix prop diffing for value and checked attributes. Close jorgebucaran#6.
NPM 5 has the new lock file format which replaces the need for yarn.
Use long command line options and sort the commands to help with debugging.
The decision is that deterministic dependencies are not desired currently due to the additional complexity.
Ensure that the lock file is not checked in the future either.
* remove default container argument; update tests and `README.md` to reflect the change * changed the argument order of `patch` and adjusted the terminlogy and README, per discussion in jorgebucaran#40
* add failing test for passing numbers in styles * handle numbers correctly in styles
* added tests for falsey attribute value handling * set attribute to blank string if === true
…pe-arguments; also, make `patch` accept `Element` rather than `HTMLElement`, because an `SVGElement` is not an `HTMLElement` (jorgebucaran#59)
Properties take precedence over attributes. Props now correctly omit the `value` attribute from the expected markup - because we're now updating the property, which is not the same as updating the attribute. Elements with falsey values now uses an attribute for the tests, rather than `value`, which is a property.
- Breaking: change the type of onremove from returning a function that receives `done`, to a function that takes both the element and `done`. onremove(element, done).
…the test that was already in place made an assertion about the state of a var `removed`, but this var was only initialized and never actually changed; the test wasn't proving anything.
- Add new ondestroy lifecycle event called both for nodes that are directly removed or removed as a result of a parent (any ancestor) node being removed. - Breaking: change the type of onremove from returning a function that receives `done`, to a function that takes both the element and `done`. onremove(element, done).
Updated test-case
Add ondestroy & refactor functions in show order.
Codecov Report
@@ Coverage Diff @@
## master #79 +/- ##
=====================================
Coverage 100% 100%
=====================================
Files 2 2
Lines 119 119
Branches 38 38
=====================================
Hits 119 119 Continue to review full report at Codecov.
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I attempted to add type-checking for
key
and the life-cycle attributes.@andrewiggins can you take a look?
This works towards #36 but doesn't complete it - we still need types for for HTML/SVG attributes.