You are reading a single comment by @Joakim and its replies. Click here to read the full conversation.
  • Why can't you use the espruino npm module directly to send your code? Or is there some reason you need to get into the REPL afterwards?

    Anyway, I'm actually making a Rollup plugin for Espruino. I hadn't thought of using Rollup for bundling Espruino projects before, but it makes perfect sense. It prefers ES modules (import … from, export default, etc), supports treeshaking, has a nice selection of plugins and produces no overhead as long as format is es (the default). For simple Espruino projects without any external dependencies it results in very nice code (before uglification of course). The result is a flattening of all your modules (treeshaken) into one file (one scope) without any wrappers/loaders.

    https://github.com/joakimstai/rollup-plu­gin-espruino

    Note: I haven't actually tested it with an Espruino device yet, as I haven't got one on me :)

About

Avatar for Joakim @Joakim started