Skip to content

Commit ca8c298

Browse files
author
Alan Smith
committed
update readme
1 parent 5b73c78 commit ca8c298

File tree

1 file changed

+25
-2
lines changed

1 file changed

+25
-2
lines changed

README.md

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,9 +126,32 @@ export default {
126126
### Using Stock/Map charts
127127
To use the stock map charts, you need to import and register them. For example, to use the map chart
128128

129-
```
129+
```js
130130
import HighCharts from 'highcharts';
131131
import useMapCharts from 'highcharts/modules/map';
132132

133133
useMapCharts(HighCharts);
134-
```
134+
```
135+
136+
```html
137+
<template>
138+
<vue-highcharts type="mapChart" :options="chartOptions"/>
139+
```
140+
141+
### Local Dev Issues.
142+
Since Vue and Highcharts are not bundled with the module, you may need to add some webpack aliases.
143+
144+
For example, the following needs to be added when using vue-cli to vue.config.js
145+
146+
```js
147+
const path = require('path');
148+
module.exports = {
149+
chainWebpack: (config) => {
150+
config.resolve.alias.set('vue$', path.join(__dirname, 'node_modules/vue'));
151+
config.resolve.alias.set('highcharts$', path.join(__dirname, 'node_modules/highcharts'));
152+
},
153+
};
154+
```
155+
156+
### License
157+
See [License.md](./LICENSE.md)

0 commit comments

Comments
 (0)