-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error if compiled with "compilerOptions" - "target": "es6" #1
Comments
I'm not sure webpack or ionic fully support ES6 yet. May I ask why you need to run your app with ES6? |
Ionic support ES6. My applications on Ionic are compiled under ES6, except for the use of TypeORM. Applications under the ES6 are much easier to debug if you use async/await. And, as far as I can see, they work a little faster, the interface is more responsive. |
TypeOrm generally supports the ES6? |
TypeORM should support ES6 but the compiled version in the package uses ES5. I haven't tried running the app or TypeORM with ES6 |
Of course typeorm supports es6.
that should be zero issues with it compiled into es5 since es6 includes all features which present in the es5, right.
@extart create a demo repository for @daniel-lang and check the issue together since I dont have ionic stuff installed and not an expert in this area. Also provide a detailed error with code example, how do we know what is |
If you run this example in Chrome (the command is "ionic serve"), then the same error occurs. |
Do you have a working Ionic example (without TypeORM) that works with ES6 and that you can share? |
I will prepare a working example and put a link here. |
A working example is the standard Ionic example. |
@daniel-lang, Is there a chance to fix it? |
@extart I finally had enough time to dive into this problem. It seems like it's exactly what @pleerock suspected in the beginning.
After removing the import statement from |
@daniel-lang Indeed, when I removed the circular relationship, it all worked. I checked in my project. In general, the problem is solved, but you probably need to somehow write about this feature in the documentation for TypeORM... |
@daniel-lang I think you can close this issue. Once again many thanks! |
I have the same issue when I try to use typeorm in connection with vue / electron. |
The problem still exists. The manyToOne relationship is not working when compiled with webpack. I just can't remove the relationship. |
Got it working when I have changed to
From
AND imported like this
Instead of There was a problem with webpack dealing with circular dependencies. |
Compilation is successful, but when starting on the device, an error occurs - main.js: 7 Uncaught ReferenceError: Author is not defined
How to compile the project under ECMAScript 6?
The text was updated successfully, but these errors were encountered: