This repository is a starter template for developing in TypeScript and HTML/CSS, using the Deno runtime and the Vite JS Build tool. The project is designed to be used with the GitHub Pages/Actions workflow.
- Installation
- Setting Up the Project
- GitHub Setup Instructions
- Installing Packages
- Managing Dependencies
- Start Developing!
To install Deno, follow the official instructions at https://deno.com/ or https://github.com/denoland/deno.
To install Vite, run the following command:
npm install vite@latestMake sure Deno is properly installed by running the following command:
deno --version- Go to your repository settings:
Settings > Pages > Build and Deployment - Set the Source to “GitHub Actions”.
- Navigate to the Actions tab in your repository.
- Click the green button labeled “Enable Actions”.
To install new packages using Deno, use the following command:
deno install npm:package-nameTo verify the installed packages:
npm list- If any installed packages are marked as extraneous, it means they are not referenced in the
package.jsonfile.
Dependencies are tracked in two files:
package.jsonfor npm packagesdeno.jsonfor the Deno runtime
Step 1: In package.json, add the dependency under "dependencies":
"dependencies": {
"package-name": "1.0.0"
}Step 2: In deno.json, add the dependency under "imports":
"imports": {
"package-name": "npm:package-name@^1.0.0"
}To start the development environment and generate the deno.lock file, run:
deno run dev