Add legacy build test map to site/index.html
This commit is contained in:
@@ -23,7 +23,7 @@
|
||||
"build-package": "npm run transpile && npm run copy-css && npm run generate-types && node tasks/prepare-package.js",
|
||||
"build-index": "shx rm -f build/index.js && npm run build-package && node tasks/generate-index.js",
|
||||
"build-legacy": "shx rm -rf build/legacy && npm run build-index && webpack --config config/webpack-config-legacy-build.mjs && cleancss --source-map src/ol/ol.css -o build/legacy/ol.css",
|
||||
"build-site": "shx rm -rf build/site && npm run build-examples && npm run apidoc && shx mkdir -p build/site && shx cp site/index.html build/site/ && shx mv build/apidoc build/examples build/site/",
|
||||
"build-site": "shx rm -rf build/site && npm run build-examples && npm run apidoc && npm run build-legacy && shx mkdir -p build/site && shx cp site/index.html build/site/ && shx mv build/apidoc build/examples build/legacy build/site/",
|
||||
"copy-css": "shx cp src/ol/ol.css build/ol/ol.css",
|
||||
"generate-types": "npx --package=typescript@3.8.3 -y -- tsc --project config/tsconfig-build.json --declaration --declarationMap --emitDeclarationOnly --outdir build/ol",
|
||||
"transpile": "shx rm -rf build/ol && shx mkdir -p build/ol && shx cp -rf src/ol build/ol/src && node tasks/serialize-workers.cjs && npx --package=typescript@4.3.5 -y -- tsc --project config/tsconfig-build.json",
|
||||
|
||||
@@ -4,11 +4,28 @@
|
||||
<title>OpenLayers</title>
|
||||
<link href='https://fonts.googleapis.com/css?family=Quattrocento+Sans:400,400italic,700' rel='stylesheet' type='text/css'>
|
||||
<link href='https://openlayers.org/assets/theme/site.css' rel='stylesheet' type='text/css'>
|
||||
<link href="./legacy/ol.css" rel='stylesheet' type='text/css'>
|
||||
</head>
|
||||
<body>
|
||||
<ul>
|
||||
<li><a href="./apidoc/">API Docs</a></li>
|
||||
<li><a href="./examples/">Examples</a></li>
|
||||
</ul>
|
||||
<div id="map" style="width:400px;height:400px;"></div>
|
||||
<script src="./legacy/ol.js"></script>
|
||||
<script>
|
||||
new ol.Map({
|
||||
target: 'map',
|
||||
layers: [
|
||||
new ol.layer.Tile({
|
||||
source: new ol.source.OSM()
|
||||
})
|
||||
],
|
||||
view: new ol.View({
|
||||
center: [0, 0],
|
||||
zoom: 0
|
||||
})
|
||||
})
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user