I tried to use ember cli to generate local project, but when visiting localhost:4200, I met below errors:
Error occurred:
- While rendering:
-top-level
application
Uncaught Error: Decorating class property failed. Please ensure that proposal-class-properties is enabled and runs after the decorators transform.
and ember -v gives this:
ember-cli: 3.28.4
node: 16.13.1
os: darwin x64
Please help to point out the reason.
Thanks
In your package.json change
"ember-cli-babel": "^7.26.6"
to
"ember-cli-babel": "7.26.6"
the credit for the answer goes to the Ember community on Discord
Related
First off all excuse the bad english..
Im develop/build using vue3 + vite2.
Deploy the 'dist' folder on AWS EC2 and run the server with nginx.
And when I connect to that page, I get an error that I can't see.
Has anyone ever seen an error like this?
(When build/run locally, it works normally without errors.)
after a day of suffering, i found that it was due vueI18n plugin in the vite.config.ts file.
import vueI18n from '#intlify/vite-plugin-vue-i18n';
import path from 'path';
// https://vitejs.dev/config/
export default defineConfig({
plugins: [vue()],
plugins: [
vue(),
vueI18n({
include: path.resolve(__dirname, './path/to/src/locales/**'),
}),
],
....
I don't know for what reason,
When I delete that plugin, it worked fine.
the reason for adding vueI18n plugin is because a warning related to bundle install occurred.
i guess is that the plugin conflicts with vite's build environment.
I am setting up ghost cms on aws for a client and hit a wall. I am using the bitnami image for setting this up. I haven't touched the config file that comes default in bitnami image. Ghost is not starting up and it's showing this error in the log
Debug Information:
OS: Debian GNU/Linux, v10
Node Version: v10.20.1
Ghost-CLI Version: 1.14.0
Environment: production
Command: 'ghost log'
An error occurred.
Message: 'Cannot read property 'join' of undefined'
Stack: TypeError: Cannot read property 'join' of undefined
at instance.isRunning.then (/opt/bitnami/apps/ghost/lib/node_modules/ghost-cli/lib/commands/log.js:34:88)
at process._tickCallback (internal/process/next_tick.js:68:7)
OK it literally wasted hours of my life. And the problem was found. The reason was that in the config file the url of the blog was given as an IP address. But Ghost has said in it's setup documentation that this is likely to cause issues. So when I changed this to a URL instead of the IP address it was fixed. Hurraaay!!
When I require mdbootrstrap in a webpacker pack, the following error is outputed:
Firefox: TypeError: "exports" is read-only
Chrome: Uncaught TypeError: Cannot assign to read only property 'exports' of object '#<Object>'
Is there a config tweak that I could make to get rid of this error? Or must I just wait for mdbootstrap owner to release a patch for this?
Any help appreciated!
Links:
Github demo app: https://github.com/yoones/rails_6_mdb_through_webpacker
Yarn package.json: https://github.com/yoones/rails_6_mdb_through_webpacker/blob/master/package.json
Webpacker env config: https://github.com/yoones/rails_6_mdb_through_webpacker/blob/master/config/webpack/environment.js
Webpacker pack: https://github.com/yoones/rails_6_mdb_through_webpacker/blob/master/app/javascript/packs/application.js
Versions:
Ruby on Rails 6.0.1
Webpacker 4.2.2
mdbootstrap 4.10.1
I have my un-ejected expo app up and running and I've managed to build and run it successfully locally on both android and iOS without errors. However, when I try to publish the app I get the unable to resolve module error.
Here's the full error:
[exp] Failed building JavaScript bundle.
[exp] Unable to resolve module `BikeShare/theme/components` from `/Users/gdaunton/Projects/BikeShare/App.js`: Module does not exist in the module map
[exp]
[exp] This might be related to https://github.com/facebook/react-native/issues/4968
[exp] To resolve try the following:
[exp] 1. Clear watchman watches: `watchman watch-del-all`.
[exp] 2. Delete the `node_modules` folder: `rm -rf node_modules && npm install`.
[exp] 3. Reset packager cache: `rm -fr $TMPDIR/react-*` or `npm start -- --reset-cache`.
[exp] Packager URL http://localhost:19001/node_modules/expo/AppEntry.bundle?dev=false&minify=true&hot=false&assetPlugin=/Users/gdaunton/Projects/BikeShare/node_modules/expo/tools/hashAssetFiles&platform=ios returned unexpected code 500. Please open your project in the Expo app and see if there are any errors. Also scroll up and make sure there were no errors or warnings when opening your project.
Basically I have a a setup like this:
BikeShare
- static
- js
- theme
- components
- index.js
- App.js
and a .babelrc with:
["module-alias", [
{ "src": "./static/js", "expose": "BikeShare" }
]]
I found out that it was because I had aliases that branched off of my main alias (i.e. BikeShare/img). I had to switch all of those to be namespaced separately (just img/). I also switched to using module-resolver instead of module-alias since that was recommended in a few places.
I'm following the directions from Here to set up a new firebase hosted app. I get to the end of the instructions and the 'ember firebase deploy' command fails. Here are the steps I'm taking:
C:\workspace\npm install -g firebase-tools
C:\workspace\cd dashdash
C:\workspace\dashdash\firebase login
C:\workspace\dashdash\npm install --save-dev ember-cli-firebase-hosting
C:\workspace\dashdash\ember generate firebase-hosting
C:\workspace\dashdash\ember firebase deploy
It works fine up until the last step. Instead of getting a success message and the URL of my app, I get the following:
C:\workspace\dashdash>ember firebase deploy
version: 1.13.8
Built project successfully. Stored in "dist".
events.js:85
throw er; // Unhandled 'error' event
^
Error: spawn C:\workspace\dashdash\node_modules\ember-cli-firebase-hosting\node_modules\firebase-tools\bin\firebase ENOENT
at exports._errnoException (util.js:746:11)
at Process.ChildProcess._handle.onexit (child_process.js:1053:32)
at child_process.js:1144:20
at process._tickCallback (node.js:355:11)
I haven't changed the app in any way when I get to that step, and I can serve it successfully to http://localhost:4200/ and get the "Welcome to Ember" message.
I'm running Windows 7 Professional (SP1) and using Windows PowerShell (run as administrator) to give the commands. I've also tried in PHPStorm's terminal.
I'm just learning about Ember, so if I've left something out (I probably have,) let me know. I'm more than happy to gather any necessary information. Any help/advice will be much appreciated.
After emailing Firebase support, I was able to get the app deployed using "firebase deploy" rather than "ember firebase deploy."