forked from pk910/PoWFaucet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.ts
24 lines (20 loc) · 789 Bytes
/
main.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import React from 'react';
import ReactDOM from 'react-dom';
import { FaucetPage, IFaucetPageProps } from './components/FaucetPage';
(() => {
let faucetProps: IFaucetPageProps = {
apiUrl: "/api",
/*
powWebsockUrl: location.origin.replace(/^http/, "ws") + "/pow",
minerSrc: {
[PoWHashAlgo.SCRYPT]: "/js/powfaucet-worker-sc.js?" + FAUCET_CLIENT_BUILDTIME,
[PoWHashAlgo.CRYPTONIGHT]: "/js/powfaucet-worker-cn.js?" + FAUCET_CLIENT_BUILDTIME,
[PoWHashAlgo.ARGON2]: "/js/powfaucet-worker-a2.js?" + FAUCET_CLIENT_BUILDTIME,
}
*/
};
var container = document.querySelector(".pow-faucet");
let faucet = React.createElement<IFaucetPageProps>(FaucetPage, faucetProps, []);
container.innerHTML = "";
ReactDOM.render(faucet, container);
})();