@xylabs/lodash 2.10.3
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/LICENSE +165 -0
- package/README.md +71 -0
- package/babel.config.json +5 -0
- package/dist/cjsIndex.d.mts +2 -0
- package/dist/cjsIndex.d.ts +2 -0
- package/dist/cjsIndex.js +5534 -0
- package/dist/cjsIndex.js.map +1 -0
- package/dist/cjsIndex.mjs +5526 -0
- package/dist/cjsIndex.mjs.map +1 -0
- package/dist/esmIndex.d.mts +1 -0
- package/dist/esmIndex.d.ts +1 -0
- package/dist/esmIndex.js +7834 -0
- package/dist/esmIndex.js.map +1 -0
- package/dist/esmIndex.mjs +7487 -0
- package/dist/esmIndex.mjs.map +1 -0
- package/jest.config.cjs +22 -0
- package/package.json +69 -0
- package/src/cjsIndex.ts +5 -0
- package/src/esmIndex.ts +2 -0
- package/tsup.config.ts +16 -0
package/jest.config.cjs
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
const generateJestConfig = ({ esModules }) => {
|
|
2
|
+
const esModuleslist = Array.isArray(esModules) ? esModules.join('|') : esModules
|
|
3
|
+
return {
|
|
4
|
+
globals: {
|
|
5
|
+
'ts-jest': {
|
|
6
|
+
tsconfig: 'tsconfig.test.json',
|
|
7
|
+
},
|
|
8
|
+
},
|
|
9
|
+
moduleNameMapper: {
|
|
10
|
+
'^(\\.{1,2}/.*)\\.js$': '$1',
|
|
11
|
+
},
|
|
12
|
+
preset: 'ts-jest/presets/default-esm',
|
|
13
|
+
testRegex: '(/__tests__/.*|(\\.|/)(test|spec))\\.tsx?$',
|
|
14
|
+
transform: {
|
|
15
|
+
[`(${esModuleslist}).+\\.js$`]: 'babel-jest',
|
|
16
|
+
'^.+\\.tsx?$': 'ts-jest',
|
|
17
|
+
},
|
|
18
|
+
transformIgnorePatterns: [`./node_modules/(?!${esModuleslist})`],
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
module.exports = generateJestConfig({ esModules: ['is-ip', 'ip-regex'] })
|
package/package.json
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
{
|
|
2
|
+
"license": "LGPL-3.0",
|
|
3
|
+
"name": "@xylabs/lodash",
|
|
4
|
+
"author": {
|
|
5
|
+
"email": "support@xylabs.com",
|
|
6
|
+
"name": "XY Labs Development Team",
|
|
7
|
+
"url": "https://xylabs.com"
|
|
8
|
+
},
|
|
9
|
+
"bugs": {
|
|
10
|
+
"email": "support@xylabs.com",
|
|
11
|
+
"url": "https://github.com/xylabs/sdk-js/issues"
|
|
12
|
+
},
|
|
13
|
+
"description": "Base functionality used throughout XY Labs TypeScript/JavaScript libraries",
|
|
14
|
+
"docs": "dist/docs.json",
|
|
15
|
+
"exports": {
|
|
16
|
+
".": {
|
|
17
|
+
"require": {
|
|
18
|
+
"types": "./dist/cjsIndex.d.ts",
|
|
19
|
+
"default": "./dist/cjsIndex.js"
|
|
20
|
+
},
|
|
21
|
+
"import": {
|
|
22
|
+
"types": "./dist/esmIndex.d.mts",
|
|
23
|
+
"default": "./dist/esmIndex.mjs"
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
"./dist/docs.json": {
|
|
27
|
+
"default": "./dist/docs.json"
|
|
28
|
+
},
|
|
29
|
+
"./docs": {
|
|
30
|
+
"default": "./dist/docs.json"
|
|
31
|
+
},
|
|
32
|
+
"./package.json": "./package.json"
|
|
33
|
+
},
|
|
34
|
+
"main": "dist/cjsIndex.js",
|
|
35
|
+
"module": "dist/esmIndex.mjs",
|
|
36
|
+
"scripts": {
|
|
37
|
+
"package-compile": "tsup && publint",
|
|
38
|
+
"package-recompile": "tsup && publint"
|
|
39
|
+
},
|
|
40
|
+
"homepage": "https://xylabs.com",
|
|
41
|
+
"keywords": [
|
|
42
|
+
"xylabs",
|
|
43
|
+
"utility",
|
|
44
|
+
"typescript",
|
|
45
|
+
"esm"
|
|
46
|
+
],
|
|
47
|
+
"optionalDependencies": {
|
|
48
|
+
"lodash": "^4.17.21",
|
|
49
|
+
"lodash-es": "^4.17.21"
|
|
50
|
+
},
|
|
51
|
+
"devDependencies": {
|
|
52
|
+
"@types/lodash": "^4.14.198",
|
|
53
|
+
"@types/lodash-es": "^4.17.9",
|
|
54
|
+
"@xylabs/ts-scripts-yarn3": "^2.19.5",
|
|
55
|
+
"@xylabs/tsconfig": "^2.19.5",
|
|
56
|
+
"publint": "^0.2.2",
|
|
57
|
+
"tsup": "^7.2.0",
|
|
58
|
+
"typescript": "^5.2.2"
|
|
59
|
+
},
|
|
60
|
+
"publishConfig": {
|
|
61
|
+
"access": "public"
|
|
62
|
+
},
|
|
63
|
+
"repository": {
|
|
64
|
+
"type": "git",
|
|
65
|
+
"url": "https://github.com/xylabs/sdk-js.git"
|
|
66
|
+
},
|
|
67
|
+
"sideEffects": false,
|
|
68
|
+
"version": "2.10.3"
|
|
69
|
+
}
|
package/src/cjsIndex.ts
ADDED
package/src/esmIndex.ts
ADDED
package/tsup.config.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { defineConfig } from 'tsup'
|
|
2
|
+
|
|
3
|
+
// eslint-disable-next-line import/no-default-export
|
|
4
|
+
export default defineConfig({
|
|
5
|
+
bundle: true,
|
|
6
|
+
cjsInterop: true,
|
|
7
|
+
clean: true,
|
|
8
|
+
dts: {
|
|
9
|
+
entry: ['src/cjsIndex.ts', 'src/esmIndex.ts'],
|
|
10
|
+
},
|
|
11
|
+
entry: ['src/cjsIndex.ts', 'src/esmIndex.ts'],
|
|
12
|
+
format: ['cjs', 'esm'],
|
|
13
|
+
sourcemap: true,
|
|
14
|
+
splitting: false,
|
|
15
|
+
tsconfig: 'tsconfig.build.json',
|
|
16
|
+
})
|