Open ronaldogmartins opened 2 years ago
Hi @SanderElias, good afternoon! Please let me know if I have registered this issue in the right place and in the right way as I have no experience asking for help with using tools directly here. Do you believe that I may have gone wrong in some configuration? Or will you try to identify what happened? In this case, do I need to provide any more details? Other info: does scully work with Ionic or just Angular? Thanks,
@ronaldogmartins Well, its explained in the (way to basic) docs page
In short, The platform-server-renderer isn't really ready for prime time but might work well for you. As you have an ionic app, that uses web components, rendering it with default Scully will not yet work well. (We have a longstanding issue for this, but found no time to work on it yet) If you use our SPS render, and follow the Ionic instructions for Universal, it probably will work pretty well, but there is no support just yet.
I will accept sponsoring to prioritize any of those issues!
π Bug report
Description
Ionic / Angular project Build ok (ionic cordova build browser or ionic build). When running "npx scully" the above error occurs. Note that the ts file was created in the ./src/app directory, but the error indicates that the js file does not exist in the /runtime directory and not in /runtime/app.
π¬ Minimal Reproduction
scully.app.config.ts: import { enableSPS, ScullyConfig } from '@scullyio/scully'; import { cpus } from 'os'; enableSPS(); export const config: ScullyConfig = { projectName: "app", spsModulePath: './src/app/app.sps.module.ts', outDir: './dist/static', maxRenderThreads: cpus().length * 3, routes: { } };
Created file ./src/app/app.sps.module.ts as in documentation: enableProdMode(); @NgModule({ imports: [ BrowserModule.withServerTransition({ appId: 'serverApp' }), AppModule, ScullyPlatformServerModule, IonicServerModule, ], providers: [], bootstrap: [AppComponent], }) export default class AppSPSModule {}
π»Your Environment
Windows Angular Version: 12.2.16 "@ionic/angular": "^5.6.14"
Scully Version: 2.1.0
π₯ Exception or Error
npx scully β Folder "./scully" used for custom plugins β new Angular build files imported β Starting servers for project "app" β Started Angular distribution server on "http://localhost:1864/" β Started Scully static server on "http://localhost:1668/" β Scully Development Server is up and running β Angular application compiled successfully Unhandled Promise rejection: Cannot find module 'C:\Apps\PasseioJa_1_0\PasseioJaApp\scully\runtime\app.sps.module.js' Require stack: