We are in the processes of setting up a test app utilizing Ionic 4 + Angular 7 utilizing Angular Universal for SSR. Upon adding Ionic into the mix, we are getting the following error when attempting to serve the application. Are gut feeling is it has something to do with SSR, but due to limited documentation and difficulty finding an example project, we have been unable to solve this mystery.
/Users/jsmith/Documents/workspace/website2.0/node_modules/@ionic/angular/dist/fesm5.js:1
(function (exports, require, module, __filename, __dirname) { import { __extends, __awaiter, __generator, __assign } from 'tslib';
^
SyntaxError: Unexpected token {
at new Script (vm.js:79:7)
at createScript (vm.js:251:10)
at Object.runInThisContext (vm.js:303:10)
at Module._compile (internal/modules/cjs/loader.js:657:28)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
Unfortunately, Ionic 4
doesn't support SSR
yet. i.e. It has known issues.
Mike Hartington@Ionic team
SSR is still something that we intend to work on supporting, but it there are a few bigger issues that require all of our attention.
SSR Issue is here
I think SSR support is close. Adam Bradley (co-founder and lead dev) has been working on something. Keep an eye on the git issue.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With