Skip to content

Commit

Permalink
Fix file imports.
Browse files Browse the repository at this point in the history
  • Loading branch information
hperrin committed Feb 20, 2020
1 parent 93d5724 commit b35a054
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -60,14 +60,19 @@

<!-- PNotify -->
<script src="dist/umd/PNotify.js"></script>
<!-- <link rel="stylesheet" href="dist/PNotify.css" /> -->
<link rel="stylesheet" href="src/PNotifyBrightTheme.css" />
<link rel="stylesheet" href="src/PNotifyMaterial.css" />
<script src="dist/umd/PNotifyButtons.js"></script>
<!-- <link rel="stylesheet" href="dist/PNotifyButtons.css" /> -->
<script src="dist/umd/PNotifyAnimate.js"></script>
<script src="dist/umd/PNotifyMobile.js"></script>
<!-- <link rel="stylesheet" href="dist/PNotifyMobile.css" /> -->
<script src="dist/umd/PNotifyDesktop.js"></script>
<!-- <link rel="stylesheet" href="dist/PNotifyDesktop.css" /> -->
<script src="dist/umd/PNotifyConfirm.js"></script>
<script src="dist/umd/PNotifyReference.js"></script>
<!-- <link rel="stylesheet" href="dist/PNotifyReference.css" /> -->

<!-- Custom Styling -->
<style type="text/css">
Expand Down
2 changes: 1 addition & 1 deletion make.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ for (const name of pnotifySrc) {
const dstFilename = 'dist/es/' + name + '.js';
let code = fs.readFileSync(srcFilename, 'utf8');

code = code.replace(/import (.*) from (["'])\.\/(\w*)\.html(["'])/g, 'import $1 from $2./$3$4');
code = code.replace(/(import|export) (.*) from (["'])\.\/(\w*)\.html(["'])/g, '$1 $2 from $3./$4.js$5');

fs.writeFileSync(dstFilename, code);
}

0 comments on commit b35a054

Please sign in to comment.