简体   繁体   中英

How can i start react site from different static html

I have a react project. When I start with npm start, it starts with index.html. But I want to start with xxx.html(static HTML). the static xxx page includes a button, when i press the button, it will redirect normal react page.

I have tried to change start-url in manifest.js , but nothing changed.

  "start_url": "./index_react.html",

How can I change that? thank you in advance.

I have fixed that with adding this.

<Route exact path="/" render={() => {window.location.href="/main.html"}} />

workaround but its okay for me.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM