prember-middleware is an Ember CLI addon designed to facilitate the testing of pre-rendered Ember applications during local development. It provides an `ember-cli` middleware that correctly serves statically pre-rendered HTML files (e.g., `about/index.html` for the `/about` route) from the `dist` directory when running `ember serve`. This is crucial because `ember serve` typically expects dynamic rendering. The package is currently at version 0.1.0, with its last known update around 2017. Given its low version number and explicit Node.js engine constraints (`6.* || >= 7.*`), it is considered abandoned. While the core `prember` addon is actively maintained (last published July 2024, v6.0.0), `prember-middleware` itself has not seen updates. Its primary differentiator is enabling a development environment that mirrors `prember`'s production output without requiring a separate static file server. It integrates directly into the `ember-cli` build pipeline, leveraging Express middleware.
npm install prember-middlewareNo compatibility data collected yet for this library.
Installs the `prember-middleware` addon and demonstrates how to activate it during `ember serve` using an environment variable, allowing local testing of pre-rendered routes.
Upgrade to a maintained middleware solution compatible with modern Ember CLI and Node.js versions. If no direct replacement exists, consider a custom `ember-cli-build.js` server middleware using Express directly or a simple static file server for testing prember output.
Evaluate if the functionality is strictly necessary. For new projects or upgrading existing ones, seek alternative, actively maintained solutions or implement the necessary server middleware manually within `ember-cli-build.js`.
Refer to the `prember` documentation regarding Embroider compatibility and ensure explicit configuration of the `prerender` function within `ember-cli-build.js`.
Use a Node.js version manager (e.g., `nvm`) to switch to a compatible Node.js version (e.g., Node 7.x or 8.x, if available and secure), or consider the addon abandoned and seek an alternative solution.
Ensure `PREMBER=true` is set when running `ember serve`. Verify that your `prember` configuration in `ember-cli-build.js` includes the desired URLs and that `prember` successfully runs during the build process to generate the static files.
No dependency data recorded yet.