#What is the Best approach to developing a bot and reloading the new changes into it?
1 messages · Page 1 of 1 (latest)

Thank you for marking this question as solved!
1063806029839728752
1063807579505041508
Umm what's the difference between hot module reloading and just reloading ( like the reloading example that was there in d.js guide )??
where does the dj guide say that?
Hot module reloading is automatic (it will reload whenever you save the file)
I think djs mentions it as a command, which just means you'd have to run a command every time
It was there earlier but they probably removed it
Oh, instead of hot module reloading, can't we just import the command/event file while executing it rather than setting it in a discordjs collection and retrieving it?
That might be possible 🤷♂️
I think you would need to clear the require cache every time then.
It wouldnt be so good for performance, the cache is there for a reason, but maybe fine for development.
Also if you want to reload things that aren't commands, you can also delete require cache for it.
mind me asking where I find resources about how to use it with esm?
the plugin is compatible with esm