Skip to Content
OneJS is updated for Unity 6.3 with native svg/vector assets support and uss filters! Here's a quick tutorial.
DocumentationUpgrading

If you’re upgrading OneJS between major versions (via any of the installation methods outlined in the Getting Started guide), you may need to reset some default config files. Here’s the list:

  • package.json
  • tsconfig.json
  • esbuild.mjs
  • postcss.config.js
  • tailwind.config.js

Just delete these from your WorkingDir (by default, that’s {ProjectDir}/App), then run your scene with the ScriptEngine prefab. OneJS will auto-generate fresh versions of those files with the latest defaults. If you’ve made custom changes, be sure to back them up first.

OneJS V1 to V2 Upgrade Notes

  • Most of the DOM APIs from V1 still work the same in V2, so you probably won’t need to change much there.
  • The Objects list on ScriptEngine has been replaced with Globals. That means you don’t need to do require("myObj") anymore. You can just use myObj directly in your JS code.
  • If you were using any Jint-specific code, you’ll need to update that to work with PuerTS instead.

TS Typing Issues

Generally you want to make sure to npm i onejs-core@latest to get the latest typings even if you are using an old Unity version. We try to provide the ts typings in a backwards-compatible way as much as possible, but sometimes there are breaking changes in the Unity API that we need to reflect in the typings. If you can’t seem to get past a typing issue, feel free to drop by our Discord server  for help.