Skip to content

Commit

Permalink
Update examples to load parser from the relative dist directory
Browse files Browse the repository at this point in the history
This ensures the parser version (after running build) is valid
because the cdn version is the most recently published one.
  • Loading branch information
remarkablemark committed Jan 26, 2017
1 parent 59a1ff7 commit 07a6d44
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion examples/requirejs.html
Expand Up @@ -13,7 +13,7 @@
<script>
requirejs.config({
paths: {
'html-react-parser': 'https://unpkg.com/html-react-parser@latest/dist/html-react-parser.min',
'html-react-parser': '../dist/html-react-parser.min',
'react': 'https://unpkg.com/react@latest/dist/react.min',
'react-dom': 'https://unpkg.com/react-dom@latest/dist/react-dom.min'
}
Expand Down
7 changes: 3 additions & 4 deletions examples/script-tag.html
Expand Up @@ -7,12 +7,11 @@
<body style="padding: 50px">
<div id="root"></div>

<!-- HTMLReactParser depends on React -->
<!-- HTMLReactParser depends on React and ReactDOM -->
<script src="https://unpkg.com/react@latest/dist/react.min.js"></script>
<script src="https://unpkg.com/html-react-parser@latest/dist/html-react-parser.min.js"></script>

<!-- ReactDOM -->
<script src="https://unpkg.com/react-dom@latest/dist/react-dom.min.js"></script>
<script src="../dist/html-react-parser.min.js"></script>

<script>
ReactDOM.render(
HTMLReactParser(
Expand Down

0 comments on commit 07a6d44

Please sign in to comment.