1.0.27 • Published 5 years ago

marvel-sitemap v1.0.27

Weekly downloads
-
License
ISC
Repository
-
Last release
5 years ago

marvel-sitemap

Install:

npm install marvel-sitemap --save

Usage:

import Sitemap from 'marvel-sitemap'

const options = {
  canvasId : 'myCanvajs', // <canvas> element id
  id: '2aah1d9', // marvel vanity id
}

// initiate a sitemap component in a canvas element
const sitemap = new Sitemap(options);

// initiate the load of the sitemap
sitemap.load()
  .then(() => {
    console.log('Sitemap Loaded')
  })

// update a config property
sitemap.update({ scale: .4, lineColor: '#ccffbb' })

// config properties available:
{
  scale: 0.2,
  spacingX: 150,
  spacingY: 50,
  marginX: 30,
  marginY: 80,
  maxPerRow: 10,
  maxPerColumn: 6,
  lineWidth: 2,
  arrow: 3,
  radius: 5,
  corridorMargin: 20,
  useSingleColor: false,
  joinLines: false,
  lineColor: '#000000',
  hotspotColor: '#0087ff',
};

// when you are done...
sitemap.destroy()

Publish

npm run build
npm publish
1.0.27

5 years ago

1.0.26

6 years ago

1.0.25

6 years ago

1.0.24

6 years ago

1.0.23

6 years ago

1.0.22

6 years ago

1.0.21

6 years ago

1.0.20

6 years ago

1.0.19

6 years ago

1.0.18

6 years ago

1.0.17

6 years ago

1.0.16

6 years ago

1.0.15

6 years ago

1.0.14

6 years ago

1.0.13

6 years ago

1.0.12

6 years ago

1.0.11

6 years ago

1.0.10

6 years ago

1.0.9

6 years ago

1.0.8

6 years ago

1.0.7

6 years ago

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago