Skip to content

[WIP] Simplify everything #1173

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

Merged
merged 16 commits into from
Feb 24, 2018
Merged

[WIP] Simplify everything #1173

merged 16 commits into from
Feb 24, 2018

Conversation

Rich-Harris
Copy link
Member

See #1122. Lots still to do, and this branch is currently rather messy, but I'm starting to think this will be a big win.

@Rich-Harris
Copy link
Member Author

Tests passing. Now to tidy up the mess I just made

@codecov-io
Copy link

codecov-io commented Feb 11, 2018

Codecov Report

Merging #1173 into master will decrease coverage by 0.02%.
The diff coverage is 94.64%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1173      +/-   ##
==========================================
- Coverage   91.75%   91.73%   -0.03%     
==========================================
  Files         127      127              
  Lines        4572     4560      -12     
  Branches     1495     1494       -1     
==========================================
- Hits         4195     4183      -12     
- Misses        159      160       +1     
+ Partials      218      217       -1
Impacted Files Coverage Δ
src/generators/nodes/Fragment.ts 100% <ø> (ø) ⬆️
src/generators/nodes/Element.ts 95.12% <ø> (ø) ⬆️
...rators/server-side-rendering/visitors/EachBlock.ts 100% <100%> (ø) ⬆️
src/generators/nodes/Component.ts 95.65% <100%> (+0.43%) ⬆️
src/generators/dom/Block.ts 96.8% <100%> (+0.37%) ⬆️
src/generators/nodes/IfBlock.ts 96.52% <100%> (-0.03%) ⬇️
src/generators/dom/index.ts 96.25% <100%> (ø) ⬆️
src/generators/nodes/EachBlock.ts 98.73% <100%> (-0.03%) ⬇️
src/generators/Generator.ts 94.14% <50%> (ø) ⬆️
src/generators/nodes/AwaitBlock.ts 91.66% <75%> (-2.62%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cde5fa1...af5a73c. Read the comment docs.

@Rich-Harris
Copy link
Member Author

Think this is probably good to squash and merge. Some follow-up work:

  • Only track contextual values (i.e. var thing = state.thing, and the equivalent statement inside the update method) in blocks that use them. Indexes only ever need to be updated for keyed each blocks
  • See if we can now move more work (e.g. diffing keyed each blocks, handling promises etc) into shared helpers, to reduce duplication

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants