@fncts/base 0.0.16 → 0.0.17
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.
|
@@ -7,14 +7,17 @@ exports.makeTag = makeTag;
|
|
|
7
7
|
|
|
8
8
|
var tsplus_module_1 = /*#__PURE__*/_interopRequireWildcard( /*#__PURE__*/require("@fncts/base/data/Tag/definition"));
|
|
9
9
|
|
|
10
|
+
var _uuid = /*#__PURE__*/require("uuid");
|
|
11
|
+
|
|
10
12
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
11
13
|
|
|
12
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
13
15
|
|
|
14
16
|
/**
|
|
15
17
|
* @tsplus static fncts.TagOps __call
|
|
18
|
+
* @fncts tag
|
|
16
19
|
*/
|
|
17
|
-
function makeTag(id) {
|
|
20
|
+
function makeTag(id = (0, _uuid.v4)()) {
|
|
18
21
|
return new tsplus_module_1.Tag(id);
|
|
19
22
|
}
|
|
20
23
|
//# sourceMappingURL=constructors.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constructors.cjs","mappings":"
|
|
1
|
+
{"version":3,"file":"constructors.cjs","mappings":";;;;;;;;;AAAA;;;;;;AAEA;;;;AAIM,SAAUA,OAAV,CAAqBC,KAAa,eAAlC,EAAsC;EAC1C,OAAO,oBAAIC,GAAJ,CAAQD,EAAR,CAAP;AACD","names":["makeTag","id","Tag"],"sourceRoot":"","sources":["../../../_src/data/Tag/constructors.ts"],"sourcesContent":[null]}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import * as tsplus_module_1 from "@fncts/base/data/Tag/definition";
|
|
2
|
+
import { v4 } from "uuid";
|
|
2
3
|
/**
|
|
3
4
|
* @tsplus static fncts.TagOps __call
|
|
5
|
+
* @fncts tag
|
|
4
6
|
*/
|
|
5
7
|
|
|
6
|
-
export function makeTag(id) {
|
|
8
|
+
export function makeTag(id = v4()) {
|
|
7
9
|
return new tsplus_module_1.Tag(id);
|
|
8
10
|
}
|
|
9
11
|
//# sourceMappingURL=constructors.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constructors.mjs","mappings":";AAAA
|
|
1
|
+
{"version":3,"file":"constructors.mjs","mappings":";AAAA,SAASA,EAAT,QAAmB,MAAnB;AAEA;;;;;AAIA,OAAM,SAAUC,OAAV,CAAqBC,KAAaF,EAAE,EAApC,EAAsC;EAC1C,OAAO,oBAAIG,GAAJ,CAAQD,EAAR,CAAP;AACD","names":["v4","makeTag","id","Tag"],"sourceRoot":"","sources":["../../../_src/data/Tag/constructors.ts"],"sourcesContent":[null]}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { Tag } from "@fncts/base/data/Tag/definition";
|
|
2
2
|
/**
|
|
3
3
|
* @tsplus static fncts.TagOps __call
|
|
4
|
+
* @fncts tag
|
|
4
5
|
* @tsplus location "@fncts/base/data/Tag/constructors"
|
|
5
6
|
*/
|
|
6
|
-
export declare function makeTag<T>(id
|
|
7
|
+
export declare function makeTag<T>(id?: string): Tag<T>;
|