Skip to content

Commit

Permalink
Merge pull request #27 from yhatt/fix-for-browser-bundler
Browse files Browse the repository at this point in the history
Fix build entry and module path for browser
  • Loading branch information
yhatt committed Feb 14, 2018
2 parents 344c16c + c8d7ff2 commit dad77f7
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
### Fixed

* Fix format script to work globstar correctly ([#26](https://github.com/yhatt/markdown-it-incremental-dom/pull/26))
* Fix build entry and module path for browser ([#27](https://github.com/yhatt/markdown-it-incremental-dom/pull/27))

## v1.2.0 - 2018-01-15

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ require('markdown-it')().use(
)
```

* **`incrementalizeDefaultRules`**: For better performance, this plugin would override a few default renderer rules only when you calls injected methods. If the other plugins that override default rules have occured any problem, You can disable overriding by setting `false`. _(`true` by default)_
* **`incrementalizeDefaultRules`**: For better performance, this plugin would override a few default renderer rules only when you calls injected methods. If the other plugins that override default rules have occurred any problem, You can disable overriding by setting `false`. _(`true` by default)_

### Rendering methods

Expand Down
2 changes: 1 addition & 1 deletion entry.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* eslint-disable import/prefer-default-export */
import markdownitIncrementalDOM from './src/markdown-it-incremental-dom'

export { markdownitIncrementalDOM }
export default markdownitIncrementalDOM
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
"version": "1.2.0",
"description": "markdown-it renderer plugin by using Incremental DOM.",
"main": "lib/markdown-it-incremental-dom.js",
"browser": "dist/markdown-it-incremental-dom.js",
"engines": {
"node": ">=4.2.0"
},
Expand Down
4 changes: 2 additions & 2 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ https://github.com/fb55/htmlparser2/raw/master/LICENSE
@license ${packageConfig.license}
${packageConfig.repository.url}/raw/master/LICENSE`

const basename = path.basename(packageConfig.browser, '.js')
const basename = path.basename(packageConfig.main, '.js')
const browsers = ['> 1%', 'last 2 versions', 'Firefox ESR', 'IE >= 9']

exports.default = {
Expand All @@ -22,7 +22,7 @@ exports.default = {
[`${basename}.min`]: './entry.js',
},
output: {
path: path.resolve(__dirname, path.dirname(packageConfig.browser)),
path: path.resolve(__dirname, 'dist'),
filename: '[name].js',
libraryTarget: 'umd',
umdNamedDefine: true,
Expand Down

0 comments on commit dad77f7

Please sign in to comment.