Avatar for ch

ch

Member since Apr 2022 • Last active Sep 2023
  • 0 conversations
  • 5 comments

Most recent activity

  • in General
    Avatar for ch

    With Stemma/QT connector please

  • in JavaScript
    Avatar for ch

    Thanks Gordon, I appreciate it's a resource-constrained platform, and already you have achieved so much on your own.

    There is a lot of flux particularly when it comes to web APIs, but ES6 has been around since 2015 or so and is a well-defined target?

    Is it helpful to make a distinction of ES6 language syntax (such as spread syntax, default parameters etc) versus the ES6 'standard library' of types and functions, eg 'String.padStart', Maps and so on?

    Could addressing the 'standard library' gap with a polyfill approach be considered? In principle it could be performed transparently by the Espruino IDE, in an optimised way (ala tree-shaking) so that polyfills are only added once and only if needed.

    This would mean a lighter memory load, even more so if the current standard library is shrunk by shifting less common functions to compile-time includes. It would also be easier for others to contribute to (by writing a 'padStart' function, for example) in contrast to helping with the the low-level Espruino interpreter.

    Gaps in language syntax, however, require writing code in a different way or introducing a transpiler. Transpiling can potentially produce very verbose code, making it less useful in a microcontroller context. The syntax gap is the bigger obstacle in terms of 'developer UX' in the context we're using Espruinos, not the 'standard library' gap.

    All that said, I'm way out of my depth with my speculations, so please forgive my ignorance 😅

  • in JavaScript
    Avatar for ch

    The discussion of ES6 language features is pertinent when using Espruino in a pedagogical context. If one is teaching students contemporary ES6 Javascript, the less one has to say "oh, sorry you can't do that on the Espruino", or "here's a totally different way to do that", the better.

    For coding pros is not problem to adapt to Espruino's limitations, or to make complicated build chains. But for beginners, this slight variation in syntax switching is not to be underestimated. Wanting to reduce this switch is a major reason we decided to start using Espruinos in our education to begin with.

    I know it's not a priority because it doesn't unlock new capabilities, but if there is a desire to target the education market as well as hobbyists, language parity should be a goal.

  • in General
    Avatar for ch

    I'd love to see a STEMMA QT / QWIIC connector for taking advantage of the Adafruit/Sparkfun ecosystem of modules. In our teaching context, it's useful when students don't have to fuss with wiring diagrams and soldering.

Actions