mirror of
https://github.com/FoggedLens/iD.git
synced 2026-02-12 16:52:50 +00:00
fetch version directly from package.json
This commit is contained in:
@@ -31,7 +31,7 @@ $ git add . && git commit -m 'npm run translations'
|
||||
```
|
||||
|
||||
- Check and finalize `CHANGELOG.md`
|
||||
- Set release version number in `modules/core/context.js` and `package.json`
|
||||
- Set release version number in `package.json`
|
||||
|
||||
```bash
|
||||
$ git add . && git commit -m 'vA.B.C'
|
||||
|
||||
@@ -4,6 +4,8 @@ import { dispatch as d3_dispatch } from 'd3-dispatch';
|
||||
import { json as d3_json } from 'd3-fetch';
|
||||
import { select as d3_select } from 'd3-selection';
|
||||
|
||||
import packageJSON from '../../package.json';
|
||||
|
||||
import { t } from '../core/localizer';
|
||||
|
||||
import { fileFetcher } from './file_fetcher';
|
||||
@@ -25,7 +27,7 @@ export function coreContext() {
|
||||
let context = utilRebind({}, dispatch, 'on');
|
||||
let _deferred = new Set();
|
||||
|
||||
context.version = '2.24.0-dev';
|
||||
context.version = packageJSON.version;
|
||||
context.privacyVersion = '20201202';
|
||||
|
||||
// iD will alter the hash so cache the parameters intended to setup the session
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import parseVersion from 'vparse';
|
||||
import { presetsCdnUrl, ociCdnUrl, wmfSitematrixCdnUrl } from '../../config/id.js';
|
||||
// Double check this resolves to iD's `package.json`
|
||||
|
||||
import packageJSON from '../../package.json';
|
||||
|
||||
let _mainFileFetcher = coreFileFetcher(); // singleton
|
||||
|
||||
Reference in New Issue
Block a user