Skip to content

Commit

Permalink
update repo
Browse files Browse the repository at this point in the history
  • Loading branch information
pi0 committed Sep 3, 2023
1 parent b9cd8ca commit e6a3d2e
Show file tree
Hide file tree
Showing 5 changed files with 89 additions and 8 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@

## Using in your pages

Checkout [./index.html](./index.html) for additional styles.
Checkout [`index.html`](./index.html) for additional styles.

```html
<div id="game"></div>
<script type="module">
import { startGame } from './index.js'
startGame({ selector: '#game' })
const { startGame } = await import("https://cdn.jsdelivr.net/gh/pi0/space-invaders/index.js");
startGame({ selector: "#game" });
</script>
```

Expand Down
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,6 @@
<div id="game"></div>

<script type="module">
import { startGame } from './index.js'
const { startGame } = await import('./index.js')
startGame({ selector: '#game' })
</script>
2 changes: 1 addition & 1 deletion index.js

Large diffs are not rendered by default.

10 changes: 7 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
{
"name": "space-invaders",
"private": true,
"repository": "pi0/space-invaders",
"scripts": {
"dev": "esbuild --serve --servedir=.",
"build": "esbuild ./index.ts --outdir=. --minify"
"build": "esbuild ./index.ts --outdir=. --minify",
"dev": "esbuild --serve --servedir=."
},
"devDependencies": {
"esbuild": "^0.19.2",
"prettier": "^3.0.3",
"terser": "^5.19.3",
"typescript": "^5.2.2"
}
},
"packageManager": "pnpm@8.7.1"
}
77 changes: 77 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit e6a3d2e

Please sign in to comment.