From f054861f963f03f198c9427959e69749ac6d351d Mon Sep 17 00:00:00 2001 From: Brandon Liu Date: Wed, 17 Feb 2021 15:08:03 +0800 Subject: [PATCH] add js package skeleton --- js/package.json | 12 ++++++++++++ js/pmtiles.js | 11 +++++++++++ 2 files changed, 23 insertions(+) create mode 100644 js/package.json create mode 100644 js/pmtiles.js diff --git a/js/package.json b/js/package.json new file mode 100644 index 0000000..ad3493b --- /dev/null +++ b/js/package.json @@ -0,0 +1,12 @@ +{ + "name": "pmtiles", + "version": "0.0.2", + "description": "PMTiles archive decoder for browsers", + "main": "pmtiles.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "homepage": "https://github.com/protomaps/pmtiles", + "author": "Brandon Liu", + "license": "BSD-3-Clause" +} diff --git a/js/pmtiles.js b/js/pmtiles.js new file mode 100644 index 0000000..4a19326 --- /dev/null +++ b/js/pmtiles.js @@ -0,0 +1,11 @@ +(function (root, factory) { + if (typeof define === 'function' && define.amd) { + define([], factory); + } else if (typeof module === 'object' && module.exports) { + module.exports = factory(); + } else { + root.pmtiles = factory(); + } +}(typeof self !== 'undefined' ? self : this, function () { + return {pmtiles:true}; +})); \ No newline at end of file