Examples Templates Store Pricing Docs Turbo CSS Blog Boomla WishList Introducing Turbo UI Named buckets Turbo CSS is Tailwind CSS on steroids Introducing Turbo CSS, the most advanced web-design language Calculate how much storage you use Better login system Collaboration settings Filesystem and Database are not cutting the problem space right What I'm working on 64bit File node IDs New how-to videos Creating buttons gets easier Introducing reusable components HTTPS by default Introducing the Boomla Theme CDN for faster pageloads Write your own website builder on top of Boomla On On composition Shared admin access A fresh config editor Building a multi-purpose theme A filesystem to replace your CMS New file link type: scope Mobile editing support Inline file wrapping changed Package sandboxing New PHP-like JavaScript engine [sjs-4e] Send emails to the website owner New JavaScript engine [sjs-4] A better editing experience New email service provider Glossary and other changes New panel changes Improved registration flow Boomla goes multiplayer Using local dev tools Why Boomla doesn't need Git File Panel Let's build a community Automatic updates Improved sjs-3 API New Frontend CSS modules Work offline with Boomla Faster page loads via caching Drag & drop supercharged Supporting CommonJS modulesĀ  Paranoid about loosing data IDE usability improvements Simple App install flow Meetups in Budapest Goodbye broken links Flow control from user space Customizing apps Contextmenu support for apps Deprecating the .Class file Hello Changelog Embedding 3rd party plugins Introducing Tools Installing apps just got amazing Public beta Host on our servers Simple deploy with push/pull Version Control for the Web 350M files on a 1TB disk 2 weeks in review
Control Panel

New JavaScript engine sjs-4

2019-06-18

Boomla has received a new ECMAScript 5.1 compilant JavaScript engine called sjs-4.

Key differences to sjs-3:

  • Full ECMAScript 5.1 support including regex and strict mode,

  • 7x faster,

  • SourceMap support.

This opens the door to running Babel, TypeScript, etc on Boomla.

It is based on the Goja VM.

Full list of differences compared to sjs-3

  • Not included:

    • os.print() - use response.body() directly,

    • os.inline(file) - use file.inline() instead,

    • app - use source instead,

    • File.prototype.placeholder() - use .bucketId() instead.

  • 'use strict' is supported. It is on by default; you can turn it off via the file attribute { "useStrict int32": 0 }.

  • Math.random() is seeded from the random attribute on the //request/info file, which contains a base64 string, currently 16 bytes long, storing a 64bit number. Its length may change in the future. You may want to override it when testing.

  • new Date() returns the current time with second granularity (the same value as returned by request.createdBy()).

  • require() asserts that the target file uses the same file type sjs-4.

  • ContentSecurityPolicy rules are not preloaded from the .ContentSecurityPolicy file. You have to set it yourself via response.attrStr('content-security-policy', '...').

Migration

The sjs-3 engine is now DEPRECATED.

It is advised to migrate to the sjs-4 engine, although the sjs-3 engine will continue to be available for at least 1 year or until all sjs-3 code has been migrated.


Cheers,

you can follow me on Twitter