FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

refactor: Migrate to Vite by rschristian · Pull Request #11 · github/codespaces-preact · GitHub

Repository navigation

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .css  (5) .ejs  (1) .html  (1) .ico  (1) .js  (11) .json  (5) .jsx  (4) .md  (1) .png  (7) .svg  (4) dotfile  (1) All 11 file types selected
Only manifest files
Deleted files Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
7 changes: 3 additions & 4 deletions .devcontainer/devcontainer.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,15 @@
"customizations": {
"codespaces": {
"openFiles": [
"src/index.js",
"src/routes/home/index.js"
"src/index.jsx"
]
}
},
"portsAttributes": {
"8080": {
"5173": {
"label": "Application",
"onAutoForward": "openPreview"
}
},
"forwardPorts": [8080]
"forwardPorts": [5173]
}
25 changes: 23 additions & 2 deletions .gitignore
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
@@ -1,3 +1,24 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
/build
/*.log
dist
dist-ssr
*.local

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
17 changes: 6 additions & 11 deletions README.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,16 @@ Everything you do here is contained within this one codespace. There is no repos

## CLI Commands

``` bash
# install dependencies
```bash
# Install dependencies
npm install

# serve with hot reload at localhost:8080
# Start a development server at localhost:5173
npm run dev

# build for production with minification
# Create a production build
npm run build

# test the production build locally
npm run serve

# run tests with jest and enzyme
npm run test
# Preview your production build locally at localhost:5173
npm run preview
```

For detailed explanation on how things work, checkout the [CLI Readme](https://github.com/developit/preact-cli/blob/master/README.md).
14 changes: 14 additions & 0 deletions index.html
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="color-scheme" content="light dark" />
<title>Vite + Preact</title>
</head>
<body>
<div id="app"></div>
<script type="module" src="/src/index.jsx"></script>
</body>
</html>
13 changes: 13 additions & 0 deletions jsconfig.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"compilerOptions": {
"target": "ES2020",
"module": "ESNext",
"moduleResolution": "bundler",
"noEmit": true,
"allowJs": true,
"checkJs": true,
"jsx": "react-jsx",
"jsxImportSource": "preact"
},
"include": ["node_modules/vite/client.d.ts", "**/*"]
}
Loading

Back | FazBrowse Home | New Git URL