To be more specific I have a react application that will not be able to be online that will have documentation available on it.
The documentation unfortunately is either only available through their websites or for download in html format instead of pdf.
https://docs.zeek.org/en/master/
other documentation is multiple html files.
I’m not sure iframe method would work in this scenario but am struggling to find solutions to my issue.
if not possible would it be possible to simply open up the application in a new tab upon clicking a button in the react app.
2
Answers
If you have offline HTML documentation that you want to include in your React application, you can embed it using an
<iframe>
element.Place the HTML documentation files within your React project (for example, in the
public
directory or a dedicated folder).Use the
<iframe>
element to display the HTML content in your React component.Something like this
You can get multiples solutions in thats link
Example:
Add html loader to your project:
Add the following rule to your webpack.config file:
Import your html file:
Link
React: how to load and render external html file?