1

I have a script that I need to import which I cannot have wrapped in a System.register call.

Is it possible to do this?

Thanks.

2 Answers 2

2

You could tell babel to ignore the module:

config.js

System.config({
  defaultJSExtensions: true,
  transpiler: "babel",
  babelOptions: {
    "ignore": [
      "github:*",
      "npm:*",
      "my/module/that/i/do/not/want/transpiled.js"
    ],
    ...

Not sure if this is exactly what you're looking for or whether the .js is needed.

Sign up to request clarification or add additional context in comments.

Comments

1

you can import the script using Globals

systemjs globals

The global format loads globals identically to if they were included via script tags but with some extra features including the ability to shim dependencies, set custom globals, and define the exports of the global module.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.