Simple HTML5 random name picker for picking lucky draw winner using Web Animations and AudioContext API
Demo is available at https://pinkylam.me/playground/random-name-picker
- Pug
- CSS3 (SCSS)
- Web Animations API
- AudioContext API
- Node 18 above or nvm installed
- Yarn or NPM installed
To install dependencies:
yarn installTo start the development server:
yarn startTo build the project for production:
yarn buildAll the build files can be found in /dist folder.
This app works fine under common static web hosting choices. Here's a general outline of the steps you can follow:
-
Set up your CI/CD pipeline to use Node.js and arn images. (If you prefer not to use a CI/CD pipeline, make sure you have both Node.js and Yarn installed on your machine.)
-
Start by installing the project dependencies. Run the command
yarn installto ensure that all the necessary npm packages are installed and ready for the build process. To optimize costs and improve the efficiency of your CI/CD pipeline, you can consider adding a cache for thenode_modulesdirectory. Check your specific CI/CD tool's documentation for cache configuration options. -
Next, you'll need to build the project. Use the command
yarn buildto initiate the build process. This command will compile and bundle the source code, generating the assets required for hosting. -
Once the build process is complete, you'll need to copy all the generated assets located under the
/distdirectory. The specific command to accomplish this may vary depending on the CI/CD tool and OS you're using. Typically, you'll need to include a step in your pipeline that copies the contents of the/distdirectory to a storage accessible by your chosen static web hosting service.