How do I deploy my web application locally?

I created a HTML 5 Boilerplate project for a school assignment and development was smooth as butter, but everything turned into a nightmare when it was time to turn in my work.

When I ran the npm install and npm run start commands, I was promptly presented with an error message stating, "Unexpected character '#'" and "private field must be enclosed within a class" or something like that. The error was apparently caused by something during compilation, because my JavaScript code was valid.

After a bit of digging around, I installed the plugin "@babel/plugin-proposal-class-properties": "^7.18.6" and created a 'babel.rc' file in my root folder, with a line I found on a StackOverflow answer.

The error message was gone, but none of my dynamically loaded images were showing. Apparently this is an issue with Parcel and there is some dumb workaround to get it work, but my real question here is: How do you create a project with sane settings and packages that allow you to quickly go from dev to release?

1 comment

Here's the first error message I encountered, which I resolved by installing the @babel/plugin-proposal-class-properties I mentioned in my previous post.


Please sign in to leave a comment.