You are reading a single comment by @fanoush and its replies. Click here to read the full conversation.
  • In addition to already mentioned minification and pretokenisation I guess it wouldn't be hard to have custom build with randomly generated token codes here https://github.com/espruino/Espruino/blob/master/src/jslex.h#L23 (same table is in the IDE) as some sort of obfuscation. This would not prevent cloning but could make dumping js code harder. Also as mentioned in that tutorial there are some builtin methods that could dump stuff to console, convert tokenized code back to source or tokenize new source when executed (so you would guess the tokens from newly entered code) so those could perhaps be removed in custom build. I guess that if the requirement would be to only run fixed set of preloaded code, the interpreter could be made more restricted regarding possibility of adding new code or doing 'dangerous' stuff via interactive console. But I guess nobody will do that for you (for free at least).

About

Avatar for fanoush @fanoush started