Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
59c3eedbab | ||
|
|
49050063d5 | ||
|
|
11024ad294 | ||
|
|
73f1428701 | ||
|
|
a579b168f7 | ||
|
|
537a21fd48 |
8
changelog/v5.0.1.md
Normal file
8
changelog/v5.0.1.md
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
# 5.0.1
|
||||||
|
|
||||||
|
The v5.0.1 release helps reduce bundle sizes for bundlers that support the `"sideEffects": "false"`option in `package.json`, and fixes website documentation regarding cdn locations and debug build which has been replaced by source maps.
|
||||||
|
|
||||||
|
## Fixes
|
||||||
|
|
||||||
|
* [#8341](https://github.com/openlayers/openlayers/pull/8341) - Set sideEffects: false flag ([@ahocevar](https://github.com/ahocevar))
|
||||||
|
* [#8342](https://github.com/openlayers/openlayers/pull/8342) - Fix links and description in quickstart tutorial ([@ahocevar](https://github.com/ahocevar))
|
||||||
7
changelog/v5.0.2.md
Normal file
7
changelog/v5.0.2.md
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
# 5.0.2
|
||||||
|
|
||||||
|
The v5.0.1 release updates the package readme with new example projects.
|
||||||
|
|
||||||
|
## Fixes
|
||||||
|
|
||||||
|
* [#8332](https://github.com/openlayers/openlayers/pull/8343) - Starter projects ([@tschaub](https://github.com/tschaub))
|
||||||
@@ -7,6 +7,9 @@ layout: doc.hbs
|
|||||||
|
|
||||||
This primer shows you how to put a simple map on a web page.
|
This primer shows you how to put a simple map on a web page.
|
||||||
|
|
||||||
|
**For production, we strongly recommend bundling the application together with its dependencies, as explained in the [Building an OpenLayers Application](./tutorials/bundle.html) tutorial.**
|
||||||
|
|
||||||
|
|
||||||
## Put a map on a page
|
## Put a map on a page
|
||||||
|
|
||||||
Below you'll find a complete working example. Create a new file, copy in the contents below, and open in a browser:
|
Below you'll find a complete working example. Create a new file, copy in the contents below, and open in a browser:
|
||||||
@@ -15,14 +18,14 @@ Below you'll find a complete working example. Create a new file, copy in the co
|
|||||||
<!doctype html>
|
<!doctype html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<link rel="stylesheet" href="https://openlayers.org/en/{{ latest }}/css/ol.css" type="text/css">
|
<link rel="stylesheet" href="https://cdn.rawgit.com/openlayers/openlayers.github.io/master/en/{{ latest }}/css/ol.css" type="text/css">
|
||||||
<style>
|
<style>
|
||||||
.map {
|
.map {
|
||||||
height: 400px;
|
height: 400px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
<script src="https://openlayers.org/en/{{ latest }}/build/ol.js" type="text/javascript"></script>
|
<script src="https://cdn.rawgit.com/openlayers/openlayers.github.io/master/en/{{ latest }}/build/ol.js"></script>
|
||||||
<title>OpenLayers example</title>
|
<title>OpenLayers example</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
@@ -56,10 +59,8 @@ To include a map a web page you will need 3 things:
|
|||||||
|
|
||||||
### Include OpenLayers
|
### Include OpenLayers
|
||||||
|
|
||||||
**Caveat:** In production, it is not recommended to include dependencies as script tag. Instead, we recommend bundling the application together with its dependencies, as explained in the [Building an OpenLayers Application](./tutorials/bundle.html) tutorial.
|
|
||||||
|
|
||||||
```xml
|
```xml
|
||||||
<script src="https://openlayers.org/en/{{ latest }}/build/ol.js" type="text/javascript"></script>
|
<script src="https://cdn.rawgit.com/openlayers/openlayers.github.io/master/en/{{ latest }}/build/ol.js"></script>
|
||||||
```
|
```
|
||||||
|
|
||||||
The first part is to include the JavaScript library. For the purpose of this tutorial, here we simply point to the openlayers.org website to get the whole library. In a production environment, we would build a custom version of the library including only the module needed for our application.
|
The first part is to include the JavaScript library. For the purpose of this tutorial, here we simply point to the openlayers.org website to get the whole library. In a production environment, we would build a custom version of the library including only the module needed for our application.
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "openlayers",
|
"name": "openlayers",
|
||||||
"version": "5.0.0",
|
"version": "5.0.2",
|
||||||
"description": "OpenLayers mapping library",
|
"description": "OpenLayers mapping library",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"map",
|
"map",
|
||||||
|
|||||||
@@ -34,11 +34,9 @@ new Map({
|
|||||||
|
|
||||||
See the following examples for more detail on bundling OpenLayers with your application:
|
See the following examples for more detail on bundling OpenLayers with your application:
|
||||||
|
|
||||||
* Using [Rollup & Uglify](https://gist.github.com/tschaub/8beb328ea72b36446fc2198d008287de)
|
* Using [Rollup](https://github.com/openlayers/ol-rollup)
|
||||||
* Using [Rollup & Closure Compiler](https://gist.github.com/tschaub/32a5692bedac5254da24fa3b12072f35)
|
* Using [Webpack](https://github.com/openlayers/ol-webpack)
|
||||||
* Using [Webpack & Uglify](https://gist.github.com/tschaub/79025aef325cd2837364400a105405b8)
|
* Using [Parcel](https://github.com/openlayers/ol-parcel)
|
||||||
* Using [Webpack & Closure Compiler](https://gist.github.com/ahocevar/8ceafc6293455ba491dd9be12c15761f)
|
|
||||||
* Using [Browserify & Uglify](https://gist.github.com/tschaub/4bfb209a8f809823f1495b2e4436018e)
|
|
||||||
|
|
||||||
## Module Identifiers
|
## Module Identifiers
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "ol",
|
"name": "ol",
|
||||||
"version": "5.0.0",
|
"version": "5.0.2",
|
||||||
"description": "OpenLayers mapping library",
|
"description": "OpenLayers mapping library",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"module": "index.js",
|
"module": "index.js",
|
||||||
@@ -9,5 +9,6 @@
|
|||||||
"pbf": "3.1.0",
|
"pbf": "3.1.0",
|
||||||
"pixelworks": "1.1.0",
|
"pixelworks": "1.1.0",
|
||||||
"rbush": "2.0.2"
|
"rbush": "2.0.2"
|
||||||
}
|
},
|
||||||
|
"sideEffects": "false"
|
||||||
}
|
}
|
||||||
@@ -52,4 +52,4 @@ export function getUid(obj) {
|
|||||||
* OpenLayers version.
|
* OpenLayers version.
|
||||||
* @type {string}
|
* @type {string}
|
||||||
*/
|
*/
|
||||||
export const VERSION = '5.0.0';
|
export const VERSION = '5.0.2';
|
||||||
|
|||||||
Reference in New Issue
Block a user