wilsonpage / fastdom

Eliminates layout thrashing by batching DOM measurement and mutation tasks
6.83k stars 240 forks source link

v1 #58

Closed wilsonpage closed 8 years ago

wilsonpage commented 9 years ago
wilsonpage commented 9 years ago

+@adaroseedwards

wilsonpage commented 9 years ago

+@pornel to review. Any 'jank' related stuff can be layered on top of this.

wilsonpage commented 9 years ago

PS. need to squash this shit.

orangemug commented 9 years ago

@wilsonpage why the 2 files (they look very similar)

./lib/fastdom.js
./fastdom.js
wilsonpage commented 9 years ago

@orangemug one is src and the other is dist. Although if you're running in CommonJS env you can just use src.

orangemug commented 9 years ago

Ah it's generated https://github.com/wilsonpage/fastdom/blob/v1-beta/package.json#L8, that was confusing. Maybe it should be in a ./dist directory?

Alternatively just remove it entirely and provide a link to https://wzrd.in/standalone/fastdom@latest

wilsonpage commented 9 years ago

Wow that's really cool! I wanted the dist to be in the root directory to make it super clear to users which file they should be using.

orangemug commented 9 years ago

The downside is that it's not clear which files people should make pull requests against though. You could add a small header as a polite note to the compiled version.

cat polite_note.txt lib/fastdom.js | ./node_modules/.bin/browserify - > fastdom.js

Where polite_note.txt is

/**
 * I am a compiled file, please don't edit me!
 */ 

Although you probably wouldn't want polite_note.txt in the base dir :)...

wilsonpage commented 9 years ago

Yeah I agree. It's a bit of a toss-up I guess. We could just compress the /fastdom.js dist so that it's obvious it's a built file? And remove the fastdom.min.js

orangemug commented 9 years ago

I assume people still like the un-minified version of files for dev? (not sure though). Really all I care about is knowing for sure which file is the one to edit for a PR.

wilsonpage commented 8 years ago

I think this is ready to land. Any objections?

kornelski commented 8 years ago

LGTM :)