@js-joda/extra 0.5.1 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,11 @@
|
|
|
3
3
|
|
|
4
4
|
### next
|
|
5
5
|
|
|
6
|
+
### 0.6.0
|
|
7
|
+
|
|
8
|
+
* [#567](https://github.com/js-joda/js-joda/pull/567) Remove generated distributions files from git ([@pithu](https://github.com/pithu))
|
|
9
|
+
* [#564](https://github.com/js-joda/js-joda/pull/564) Fix travis for PR's from forks ([@pithu](https://github.com/pithu))
|
|
10
|
+
|
|
6
11
|
### 0.5.0
|
|
7
12
|
|
|
8
13
|
* Upgrade dependencies #555 by @pithu
|
package/dist/js-joda-extra.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
//! @version @js-joda/extra - 0.
|
|
1
|
+
//! @version @js-joda/extra - 0.6.0
|
|
2
2
|
//! @copyright (c) 2015-2016, Philipp Thürwächter, Pattrick Hüper & js-joda contributors
|
|
3
3
|
//! @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
|
|
4
4
|
//! @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
//! @version @js-joda/extra - 0.
|
|
1
|
+
//! @version @js-joda/extra - 0.6.0
|
|
2
2
|
//! @copyright (c) 2015-2016, Philipp Thürwächter, Pattrick Hüper & js-joda contributors
|
|
3
3
|
//! @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
|
|
4
4
|
//! @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
|
package/package.json
CHANGED
|
@@ -1,15 +1,32 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@js-joda/extra",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "additional date-time classes that complement those in js-joda",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/js-joda/js-joda.git"
|
|
8
8
|
},
|
|
9
|
-
"
|
|
9
|
+
"author": "phueper",
|
|
10
|
+
"contributors": [
|
|
11
|
+
"pithu",
|
|
12
|
+
"phueper"
|
|
13
|
+
],
|
|
14
|
+
"homepage": "https://js-joda.github.io/js-joda",
|
|
15
|
+
"license": "BSD-3-Clause",
|
|
16
|
+
"bugs": {
|
|
17
|
+
"url": "https://github.com/js-joda/js-joda/issues"
|
|
18
|
+
},
|
|
19
|
+
"typings": "typings/js-joda-extra.d.ts",
|
|
20
|
+
"files": [
|
|
21
|
+
"dist",
|
|
22
|
+
"src",
|
|
23
|
+
"typings",
|
|
24
|
+
"CHANGELOG.md",
|
|
25
|
+
"README.md"
|
|
26
|
+
],
|
|
10
27
|
"main": "dist/js-joda-extra.js",
|
|
11
28
|
"scripts": {
|
|
12
|
-
"
|
|
29
|
+
"prepublishOnly": "npm run build-dist",
|
|
13
30
|
"test": "npx mocha --timeout 5000 --require @babel/register ./test/*Test.js ./test/**/*Test.js ./test/**/**/*Test.js test/pluginTest_mochaOnly.js",
|
|
14
31
|
"test-coverage": "NODE_ENV=test COVERAGE=1 npx nyc --report-dir=build/coverage --reporter=lcov --reporter html npx mocha --timeout 5000 --require @babel/register --reporter progress ./test/*Test.js ./test/**/*Test.js ./test/**/**/*Test.js",
|
|
15
32
|
"test-browser": "npx karma start --reporters=dots --single-run",
|
|
@@ -29,17 +46,11 @@
|
|
|
29
46
|
"sourceMap": false,
|
|
30
47
|
"instrument": false
|
|
31
48
|
},
|
|
32
|
-
"author": "phueper",
|
|
33
|
-
"contributors": [
|
|
34
|
-
"pithu",
|
|
35
|
-
"phueper"
|
|
36
|
-
],
|
|
37
|
-
"license": "BSD-3-Clause",
|
|
38
49
|
"peerDependencies": {
|
|
39
50
|
"@js-joda/core": ">=1.11.0"
|
|
40
51
|
},
|
|
41
52
|
"devDependencies": {
|
|
42
|
-
"@js-joda/core": "^4.
|
|
53
|
+
"@js-joda/core": "^4.3.0"
|
|
43
54
|
},
|
|
44
|
-
"gitHead": "
|
|
55
|
+
"gitHead": "cdc181e107e04638303605e304e78eaba5864ea0"
|
|
45
56
|
}
|
|
File without changes
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<!--
|
|
3
|
-
~ @copyright (c) 2016, Philipp Thuerwaechter & Pattrick Hueper
|
|
4
|
-
~ @license BSD-3-Clause (see LICENSE.md in the root directory of this source tree)
|
|
5
|
-
-->
|
|
6
|
-
|
|
7
|
-
<html lang="en">
|
|
8
|
-
<head>
|
|
9
|
-
<meta charset="UTF-8">
|
|
10
|
-
<title>js-joda-extra Usage Example</title>
|
|
11
|
-
<script type="text/javascript" src="../node_modules/js-joda/dist/js-joda.js"></script>
|
|
12
|
-
<script type="text/javascript" src="../dist/js-joda-extra.js"></script>
|
|
13
|
-
</head>
|
|
14
|
-
<body>
|
|
15
|
-
<div class="out" />
|
|
16
|
-
<script type="text/javascript">
|
|
17
|
-
document.addEventListener('DOMContentLoaded', function () {
|
|
18
|
-
function output(s) {
|
|
19
|
-
console.log(s);
|
|
20
|
-
var outDiv = document.getElementsByClassName('out')[0];
|
|
21
|
-
var p = document.createElement('p');
|
|
22
|
-
p.innerHTML = s;
|
|
23
|
-
outDiv.appendChild(p);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
var startInstant = JSJoda.ZonedDateTime.of(2016, 11, 7, 0, 0, 0, 0, JSJoda.ZoneOffset.UTC).toInstant();
|
|
27
|
-
var innerInstant = startInstant.plus(1, JSJoda.ChronoUnit.DAYS);
|
|
28
|
-
var endInstant = startInstant.plus(2, JSJoda.ChronoUnit.DAYS);
|
|
29
|
-
var outerInstant = startInstant.plus(3, JSJoda.ChronoUnit.DAYS);
|
|
30
|
-
var interval = new JSJodaExtra.Interval(startInstant, endInstant);
|
|
31
|
-
output('toString:' + interval.toString());
|
|
32
|
-
output('contains inner:' + interval.contains(innerInstant));
|
|
33
|
-
output('contains outer:' + interval.contains(outerInstant));
|
|
34
|
-
}, false);
|
|
35
|
-
</script>
|
|
36
|
-
</body>
|
|
37
|
-
</html>
|
package/examples/usage_node.js
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* @copyright (c) 2016, Philipp Thuerwaechter & Pattrick Hueper
|
|
3
|
-
* @license BSD-3-Clause (see LICENSE.md in the root directory of this source tree)
|
|
4
|
-
*/
|
|
5
|
-
/* eslint-disable no-console, no-var */
|
|
6
|
-
var joda = require('@js-joda/core');
|
|
7
|
-
var jodaExtra = require('../dist/js-joda-extra');
|
|
8
|
-
|
|
9
|
-
var startInstant = joda.ZonedDateTime.of(2016, 11, 7, 0, 0, 0, 0, joda.ZoneOffset.UTC).toInstant();
|
|
10
|
-
var innerInstant = startInstant.plus(1, joda.ChronoUnit.DAYS);
|
|
11
|
-
var endInstant = startInstant.plus(2, joda.ChronoUnit.DAYS);
|
|
12
|
-
var outerInstant = startInstant.plus(3, joda.ChronoUnit.DAYS);
|
|
13
|
-
var interval = new jodaExtra.Interval(startInstant, endInstant);
|
|
14
|
-
console.log('toString:', interval.toString());
|
|
15
|
-
console.log('contains inner:', interval.contains(innerInstant));
|
|
16
|
-
console.log('contains outer:', interval.contains(outerInstant));
|