Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zakimohammed/geekle-vite-app
Vite for TypeScript | Geekle TypeScript Junior Session 2023
https://github.com/zakimohammed/geekle-vite-app
geekle ts typescript vite vitets
Last synced: about 18 hours ago
JSON representation
Vite for TypeScript | Geekle TypeScript Junior Session 2023
- Host: GitHub
- URL: https://github.com/zakimohammed/geekle-vite-app
- Owner: ZakiMohammed
- Created: 2023-05-04T00:23:44.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2023-05-04T00:46:04.000Z (over 1 year ago)
- Last Synced: 2024-11-10T10:12:45.751Z (about 2 months ago)
- Topics: geekle, ts, typescript, vite, vitets
- Language: TypeScript
- Homepage: https://geekle-vite-app.netlify.app/
- Size: 19.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Vite for TypeScript - Geekle
Geekle TypeScript Junior Session 2023.
App Link: https://geekle-vite-app.netlify.app/
### Initial Setup
```
npm create vite@latest# or
npm create vite@latest geekle-vite-app --template vanilla-ts
```For `TypeScript` add this package too, for Type Safety checks, otherwise Vite only transpile the code and doesn't do the type checking:
```
npm i vite-plugin-checker -D
```Create `vite.config.js` file and add below config:
```
import checker from 'vite-plugin-checker';
export default {
plugins: [
checker({
typescript: true,
}),
],
};
```### Run Application
Update the port to `4000` in the `package.json` file `dev` script command.
```
npm run dev
```### Debug Application
For debugging go to VS Code `Run and Debug` side menu, click on the button `Debug URL`. Copy paste the running application URL to the option. This will create `.vscode` folder and adds `launch.json` file looks like this:
```
{
"configurations": [
{
"type": "msedge",
"name": "http://localhost:4000/",
"request": "launch",
"url": "http://localhost:4000/"
}
]
}
```### Build Application
To build the application run below command:
```
npm run build
```Preview built application:
```
npm run preview
```