It's hard to get the idea down from one's head into a document, as this text shows.
(ab?)using Node module hooks to speed up development
11–17 of 17 posts
Re: (ab?)using Node module hooks to speed up development
#12Re: (ab?)using Node module hooks to speed up development
#13Earlier quoted context omitted.
Using. But also maybe abusing.
I think he's proposing a fix for the regex in the title. /(ab?)using/ matches: - ausing - abusing while /(ab)?using/ matches: - using - abusing
Re: (ab?)using Node module hooks to speed up development
#14With Typescript you could(prob still can) specify how JSX tags are translated, so you can get the regular data structure without React dependency.
Re: (ab?)using Node module hooks to speed up development
#15Re: (ab?)using Node module hooks to speed up development
#16This is a reinvention of HMR, no?
Consider Vite's node-side HMR implementation. It creates its own module system on top of Node's native module system, using `node:vm`. So its modules are really second class citizens that have to be glued to the native module system.
This library used to do that, but moved to using Node's native module hooks, so that there's nothing magical going on, and you can still use the `import` expression to import your HMR modules, they just auto-update when saving.