Comments (7)
I have created the above pull request which I hope will resolve this.
from tslib.
I am sorry this is causing problems. What is going on here is that tslib main is now configured to point at the ES module entry point - tslib.es6.js
. This was done because systemjs 0.20 did not seem to be detecting the module type of the UMD version correctly (see frankwallis/plugin-typescript#199) and also it will enable rollup support to remove unused helper functions when bundling.
The workarounds I can think of are:
a) Provide a local override which points tslib main back to tslib.js
b) Change the registry to point main back to tslib.js but set the format of the file (probably to cjs?)
When you say SystemJS refuses to load the file, do you means it errors with 'export is not defined' or similar?
from tslib.
@frankwallis I've also been playing with this for a few hours. Here's what I have so far in regards to pointing to a different file:
packages: {
"tslib": {
"main": "tslib.js",
"format": "amd"
}
}
This loads, however SystemJS doesn't seem to be executing the file (errors along the lines of tslib_1.__metadata is not a function
). I've tried playing with the format
as well, but it doesn't help.
from tslib.
With [email protected]
on my Windows PC jsm_packages/[email protected]
is using require
and on macOS it appears to be using the ES6 above.
How did I end up with them differing with the same version of tslib
and jspm
?
Edit
Ah, I see the registry has been updated!
from tslib.
Thus far, the only way I have managed to force it to work, was by
adding "npm:[email protected]": "jspm_packages/npm/[email protected]/tslib"
to paths
in config.js
and removing "format esm";
from the top of jspm_packages/[email protected]/tslib.js
.
But obviously, this is not an acceptable fix, as we can't rely on modifying files like that - and I don't understand why it's adding "format esm";
to that file in the first place - it seems to be messed up.
from tslib.
Many apologies for the issues this caused. jspm/registry#1041 has now been merged. Please let us know if you continue to experience issues
from tslib.
Going to close this issue as it looks sorted ππ»
from tslib.
Related Issues (20)
- Use standard `exports` in `package.json` HOT 3
- __importDefault method may return an object with undefined default property HOT 2
- __assign is not a function
- Type 'boolean' is not assignable to parameter of type '(false | Observable<false>) & (true | Observable<true>) HOT 1
- CI: set minimal permissions for GitHub Workflows HOT 1
- TypeError: (0 , tslib__WEBPACK_IMPORTED_MODULE_0__.__rest) is not a function HOT 1
- Should tslib be in peerDependencies or just dependencies when building a library? HOT 3
- [2.5.1][Regression] imported helper named '__decorate' does not exist in 'tslib' HOT 6
- ERROR in bundle from UglifyJs Unexpected token: punc (,) HOT 8
- Regression in [email protected] when using private fields i.c.m. with ESM HOT 3
- Cannot find module '...node_modules/tslib/modules/index.js' imported from chunks/app/server.mjs HOT 2
- Generate SLSA Build L3 provenance HOT 4
- tslib >=2.5.1 regression - increases bundle size caused by noop `Object.create;` statements
- calls to tslib __setFunctionName fail on Cobalt 9 HOT 5
- Suggest an dependabot to keep GitHub Actions updated HOT 1
- Regression failure upgrading from 2.5.0 to 2.5.1+, webpack fails to transpile new export statement for ES5. HOT 1
- Performance improvement HOT 2
- The spread (...) syntax allows an stringοΌbut __spreadArray does not support string. HOT 2
- Why do I get compilation results of tslib imports containing native absolute path? HOT 2
- this appears to be a dev-dependency, but the instructions point it to be a dependency HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tslib.