hot-module-replacement icon indicating copy to clipboard operation
hot-module-replacement copied to clipboard

Add lifecycle hooks, add typescript types, run prettier

Open petehunt opened this issue 5 years ago • 5 comments

hey, thanks for a neat project. i'm messing around with building a hot reloading test runner and i needed some lifecycle hooks to know what was going on. i also added some types and ran it thru prettier.

petehunt avatar May 08 '20 07:05 petehunt

Thanks Pete! Could you add prettier config you used so that future edits are consistent?

sidorares avatar May 08 '20 08:05 sidorares

Also if "onReloaded" hook is not part of webpack HMR api we need to add a line to readme ( index.d.ts is also great as documentation, thanks for adding that! )

sidorares avatar May 08 '20 08:05 sidorares

will try to get to that this weekend :)

petehunt avatar May 09 '20 01:05 petehunt

@sidorares would you accept a PR to typescript-ify this project?

petehunt avatar May 10 '20 19:05 petehunt

would you accept a PR to typescript-ify this project?

yes, as long as it's still usable from vanilla js projects.

I also have plans to add proper ejs hooks via vm.Module but never have enough time to do that and whenever I return all my research is outdated

sidorares avatar May 10 '20 22:05 sidorares