removed notes file
Before adoption: this commit came in with the history the project adopted, so no landing records it.
authored by Michel Weststrate · committed by Michel Weststrate · parent 3cfd621 · Browse files · 2 files·+7 added−124 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
2 files+7 added−124 removed
- other:+7 added−124 removed
Provenance
- Commit
d676e61- Tree
9e6c8b0- Author
Michel Weststrate <mweststrate@fb.com>- Committer
Michel Weststrate <mweststrate@fb.com>- Parent
3cfd621
2 files changed+7 added−124 removed
modified:docs/installation.md+7 added-7 removed
52 unmodified lines535455565757585960616263646566616263646566676869705 unmodified lines52 unmodified lines
Vanilla Immer kicks in at ~3KB gzipped. Every plugin that is enabled adds < 1 KB to that. The breakdown is as follows:
```Import size report for immer (minified, gzipped, in bytes):Import size report for immer:┌───────────────────────┬───────────┬────────────┬───────────┐│ (index) │ just this │ cumulative │ increment │├───────────────────────┼───────────┼────────────┼───────────┤│ import * from 'immer' │ 5610 │ 0 │ 0 ││ produce │ 3141 │ 3141 │ 0 ││ enableES5 │ 3926 │ 3934 │ 793 ││ enableMapSet │ 3940 │ 4704 │ 770 ││ enablePatches │ 3839 │ 5391 │ 687 ││ enableAllPlugins │ 5387 │ 5425 │ 34 ││ import * from 'immer' │ 5606 │ 0 │ 0 ││ produce │ 3085 │ 3085 │ 0 ││ enableES5 │ 3870 │ 3878 │ 793 ││ enableMapSet │ 3893 │ 4654 │ 776 ││ enablePatches │ 3826 │ 5387 │ 733 ││ enableAllPlugins │ 5382 │ 5421 │ 34 │└───────────────────────┴───────────┴────────────┴───────────┘(this report was generated by npmjs.com/package/import-size)```
5 unmodified linesdeleted:notes.txt-117 removed
1-Things to optimize2-3-[x] extract errors4-[x] don't enable all features by default5-[ ] "undefined" "object" "function" prototype undefined bind, getOwnPropertyies, isArray etc + buildin FNs ?6-[x] kill hooks7-[x] _ postfix all members8-[x] clean up finalize9-[x] remove die10-[x] own invariant11-[x] update docs12-[x] plugin tests13-[x] check if we can create more local vars14-[x] verify performance15-[ ] kill ownKeys?16-[x] kill enumerations17-[x] check todos18-[ ] ~~kill marchChangesSweep recursive if possible and no perf impact~~ does have perf impact19-[ ] optimize each closures away? pass in additional args?20-[x] document performance tip: if externally added data is frozen, it doesn't recurse (also update related issue) #46521-[x] put some invariants behind __DEV__22-[x] check for plugin specific utils23-[ ] bind util24-[ ] eliminate switches25-26-Import size report for immer:27-┌───────────────────────┬───────────┬────────────┬───────────┐28-│ (index) │ just this │ cumulative │ increment │29-├───────────────────────┼───────────┼────────────┼───────────┤30-│ import * from 'immer' │ 6761 │ 0 │ 0 │31-│ produce │ 4048 │ 4048 │ 0 │32-│ enableES5 │ 4908 │ 4916 │ 868 │33-│ enableMapSet │ 5007 │ 5769 │ 853 │34-│ enablePatches │ 4836 │ 6544 │ 775 │35-└───────────────────────┴───────────┴────────────┴───────────┘36-(this report was generated by npmjs.com/package/import-size)37-38----39-40-Extracted errors41-42-Import size report for immer:43-┌───────────────────────┬───────────┬────────────┬───────────┐44-│ (index) │ just this │ cumulative │ increment │45-├───────────────────────┼───────────┼────────────┼───────────┤46-│ import * from 'immer' │ 6271 │ 0 │ 0 │47-│ produce │ 3727 │ 3727 │ 0 │48-│ enableES5 │ 4516 │ 4524 │ 797 │49-│ enableMapSet │ 4589 │ 5348 │ 824 │50-│ enablePatches │ 4444 │ 6054 │ 706 │51-└───────────────────────┴───────────┴────────────┴───────────┘52-(this report was generated by npmjs.com/package/import-size)53-54-Mangled props:55-56-Import size report for immer:57-┌───────────────────────┬───────────┬────────────┬───────────┐58-│ (index) │ just this │ cumulative │ increment │59-├───────────────────────┼───────────┼────────────┼───────────┤60-│ import * from 'immer' │ 6132 │ 0 │ 0 │61-│ produce │ 3613 │ 3613 │ 0 │62-│ enableES5 │ 4420 │ 4428 │ 815 │63-│ enableMapSet │ 4439 │ 5227 │ 799 │64-│ enablePatches │ 4319 │ 5929 │ 702 │65-└───────────────────────┴───────────┴────────────┴───────────┘66-(this report was generated by npmjs.com/package/import-size)67-68-After hooks:[69- Import size report for immer:70-┌───────────────────────┬───────────┬────────────┬───────────┐71-│ (index) │ just this │ cumulative │ increment │72-├───────────────────────┼───────────┼────────────┼───────────┤73-│ import * from 'immer' │ 5983 │ 0 │ 0 │74-│ produce │ 3454 │ 3454 │ 0 │75-│ enableES5 │ 4270 │ 4278 │ 824 │76-│ enableMapSet │ 4285 │ 5079 │ 801 │77-│ enablePatches │ 4154 │ 5770 │ 691 │78-└───────────────────────┴───────────┴────────────┴───────────┘79-(this report was generated by npmjs.com/package/import-size)80-]81-82-After finalize cleanup: [83- Import size report for immer:84-┌───────────────────────┬───────────┬────────────┬───────────┐85-│ (index) │ just this │ cumulative │ increment │86-├───────────────────────┼───────────┼────────────┼───────────┤87-│ import * from 'immer' │ 5911 │ 0 │ 0 │88-│ produce │ 3397 │ 3397 │ 0 │89-│ enableES5 │ 4199 │ 4208 │ 811 │90-│ enableMapSet │ 4217 │ 5001 │ 793 │91-│ enablePatches │ 4091 │ 5693 │ 692 │92-└───────────────────────┴───────────┴────────────┴───────────┘93-(this report was generated by npmjs.com/package/import-size)94-]95-96-Killed enumerations: 97-98-Import size report for immer:99-┌───────────────────────┬───────────┬────────────┬───────────┐100-│ (index) │ just this │ cumulative │ increment │101-├───────────────────────┼───────────┼────────────┼───────────┤102-│ import * from 'immer' │ 5750 │ 0 │ 0 │103-│ produce │ 3252 │ 3252 │ 0 │104-│ enableES5 │ 4046 │ 4055 │ 803 │105-│ enableMapSet │ 4071 │ 4847 │ 792 │106-│ enablePatches │ 3936 │ 5528 │ 681 │107-└───────────────────────┴───────────┴────────────┴───────────┘108-(this report was generated by npmjs.com/package/import-size)109-110-Minimize plugin api's:111- 3196112-113-add draft optimization114-3199115-116-invariant117-3094