Skip to content

Commit 4d47c7d

Browse files
authored
Remove GitHub Pages deploy action (#328)
* remove github pages deployment * switch to BrowserRouter
1 parent d1d37b9 commit 4d47c7d

File tree

7 files changed

+10
-65
lines changed

7 files changed

+10
-65
lines changed

Diff for: .github/workflows/deploy.yml

-24
This file was deleted.

Diff for: README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ We recommend running a [Substrate Contracts Node](https://github.com/paritytech/
1414

1515
### Contract instantiation
1616

17-
Once you have a compiled contract and you are connected to a node, you can use the hosted version of Contracts UI to [add a new contract on-chain](https://paritytech.github.io/contracts-ui/#/instantiate).
17+
Once you have a compiled contract and you are connected to a node, you can use the hosted version of Contracts UI to [add a new contract on-chain](https://contracts-ui.substrate.io/add-contract).
1818

1919
There are 2 instantiation methods:
2020

Diff for: cypress/integration/contracts/erc20.spec.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ describe('ERC20 Contract ', () => {
77
const timeout = 25000;
88

99
it('contract file uploads', () => {
10-
cy.visit('http://localhost:8081/#/instantiate');
10+
cy.visit('http://localhost:8081/instantiate');
1111
cy.get('[data-cy="file-input"]').attachFile('erc20.contract');
1212
cy.get('[data-cy="next-btn"]').should('not.be.disabled');
1313
});

Diff for: cypress/integration/contracts/flipper.spec.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ describe('Flipper Contract ', () => {
55
const timeout = 25000;
66

77
it('contract file uploads', () => {
8-
cy.visit('http://localhost:8081/#/instantiate');
8+
cy.visit('http://localhost:8081/instantiate');
99
cy.get('[data-cy="file-input"]').attachFile('flipper.contract');
1010
cy.get('[data-cy="next-btn"]').should('not.be.disabled');
1111
});

Diff for: package.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@
44
"description": "Substrate Contracts UI",
55
"private": true,
66
"type": "module",
7-
"homepage": "https://paritytech.github.io/contracts-ui",
7+
"homepage": "https://contracts-ui.substrate.io",
88
"scripts": {
99
"start": "vite",
1010
"build": "tsc && vite build",
11-
"build-github-pages": "tsc && vite build --config vite.config.ghp.ts",
1211
"lint": "yarn eslint --fix .",
1312
"format": "yarn prettier --write .",
1413
"clean": "rm -rf dist",

Diff for: src/ui/index.tsx

+6-6
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
import { Buffer } from 'buffer';
55
import { createRoot } from 'react-dom/client';
6-
import { HashRouter, Route, Routes } from 'react-router-dom';
6+
import { BrowserRouter, Route, Routes } from 'react-router-dom';
77
import App from 'ui/components/App';
88
import './styles/main.css';
99
import '@polkadot/api-augment';
@@ -26,19 +26,19 @@ const container = document.getElementById('app-root');
2626
const root = createRoot(container!);
2727

2828
root.render(
29-
<HashRouter>
29+
<BrowserRouter>
3030
<Routes>
3131
<Route path="/" element={<App />}>
3232
<Route index element={<Homepage />} />
3333
<Route path="add-contract" element={<AddContract />} />
3434
<Route path="hash-lookup" element={<SelectCodeHash />} />
35-
<Route path="/instantiate" element={<Instantiate />}>
35+
<Route path="instantiate" element={<Instantiate />}>
3636
<Route path=":codeHash" />
3737
</Route>
38-
<Route path="/contract/:address/" element={<Contract />} />
39-
<Route path="/settings" element={<Settings />} />
38+
<Route path="contract/:address/" element={<Contract />} />
39+
<Route path="settings" element={<Settings />} />
4040
<Route path="*" element={<NotFound />} />
4141
</Route>
4242
</Routes>
43-
</HashRouter>
43+
</BrowserRouter>
4444
);

Diff for: vite.config.ghp.ts

-30
This file was deleted.

0 commit comments

Comments
 (0)