Skip to content

Commit 5c2303a

Browse files
committed
build: set-up build en gh-pages
1 parent 86ce5a2 commit 5c2303a

7 files changed

+205
-7
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
/tmp
2+
/dist
23

34
# Dependency directory
45
/node_modules

demo/main.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React from 'react';
22
import ReactDOM from 'react-dom/client';
3-
import Demo from './Demo';
3+
import Demo from './DemoFull';
44

55
ReactDOM.createRoot(document.getElementById('root')!).render(
66
<Demo />

demo/index.html index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
5-
<link rel="icon" type="image/svg+xml" href="https://www.flaticon.com/free-icons/alt" />
5+
<!-- <link rel="icon" type="image/svg+xml" href="https://www.flaticon.com/free-icons/alt" /> -->
66
<link rel="stylesheet" href="https://unpkg.com/higlass@1.12/dist/hglib.css">
77
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
88
<title>AltGosling</title>
99
</head>
1010
<body>
1111
<div id="root"></div>
12-
<script type="module" src="./main.tsx"></script>
12+
<script type="module" src="./demo/main.tsx"></script>
1313
</body>
1414
</html>

package.json

+6-1
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
{
2-
"name": "demo",
2+
"name": "alt_gosling_demo",
33
"private": true,
44
"version": "0.0.0",
5+
"homepage": "https://thomcsmits.github.io/alt-gosling/",
56
"type": "module",
67
"scripts": {
8+
"predeploy" : "npm run build",
9+
"deploy" : "gh-pages -d dist/demo",
710
"dev": "vite",
11+
"build-only": "vite build",
812
"build": "tsc && vite build",
913
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
1014
"preview": "vite preview"
@@ -29,6 +33,7 @@
2933
"eslint": "^8.45.0",
3034
"eslint-plugin-react-hooks": "^4.6.0",
3135
"eslint-plugin-react-refresh": "^0.4.3",
36+
"gh-pages": "^6.1.0",
3237
"typescript": "^5.0.2",
3338
"vite": "^4.4.5"
3439
}

0 commit comments

Comments
 (0)