@x-oasis/is-ref 0.0.16

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/README.md ADDED
@@ -0,0 +1,19 @@
1
+ # @x-oasis/clamp
2
+
3
+ ## Installation
4
+
5
+ ```bash
6
+ $ npm i @x-oasis/clamp
7
+ ```
8
+
9
+ ## How to use
10
+
11
+ ```typescript
12
+ import clamp from '@x-oasis/clamp'
13
+ ```
14
+
15
+ ## How to run test
16
+
17
+ ```bash
18
+ $ pnpm test
19
+ ```
@@ -0,0 +1,2 @@
1
+ declare const _default: (obj: any) => any;
2
+ export default _default;
package/dist/index.js ADDED
@@ -0,0 +1,8 @@
1
+
2
+ 'use strict'
3
+
4
+ if (process.env.NODE_ENV === 'production') {
5
+ module.exports = require('./is-ref.cjs.production.min.js')
6
+ } else {
7
+ module.exports = require('./is-ref.cjs.development.js')
8
+ }
@@ -0,0 +1,14 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
6
+
7
+ var isObject = _interopDefault(require('@x-oasis/is-object'));
8
+
9
+ var index = (function (obj) {
10
+ return isObject(obj) && obj['current'];
11
+ });
12
+
13
+ exports.default = index;
14
+ //# sourceMappingURL=is-ref.cjs.development.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"is-ref.cjs.development.js","sources":["../src/index.ts"],"sourcesContent":["import isObject from '@x-oasis/is-object';\n\nexport default (obj: any) => isObject(obj) && obj['current'];\n"],"names":["obj","isObject"],"mappings":";;;;;;;;AAEA,aAAe,UAACA,GAAQ;EAAA,OAAKC,QAAQ,CAACD,GAAG,CAAC,IAAIA,GAAG,CAAC,SAAS,CAAC;AAAA;;;;"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=(e=require("@x-oasis/is-object"))&&"object"==typeof e&&"default"in e?e.default:e;exports.default=function(e){return t(e)&&e.current};
2
+ //# sourceMappingURL=is-ref.cjs.production.min.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"is-ref.cjs.production.min.js","sources":["../src/index.ts"],"sourcesContent":["import isObject from '@x-oasis/is-object';\n\nexport default (obj: any) => isObject(obj) && obj['current'];\n"],"names":["obj","isObject"],"mappings":"sLAEgBA,GAAQ,OAAKC,EAASD,IAAQA,EAAa"}
@@ -0,0 +1,8 @@
1
+ import isObject from '@x-oasis/is-object';
2
+
3
+ var index = (function (obj) {
4
+ return isObject(obj) && obj['current'];
5
+ });
6
+
7
+ export default index;
8
+ //# sourceMappingURL=is-ref.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"is-ref.esm.js","sources":["../src/index.ts"],"sourcesContent":["import isObject from '@x-oasis/is-object';\n\nexport default (obj: any) => isObject(obj) && obj['current'];\n"],"names":["obj","isObject"],"mappings":";;AAEA,aAAe,UAACA,GAAQ;EAAA,OAAKC,QAAQ,CAACD,GAAG,CAAC,IAAIA,GAAG,CAAC,SAAS,CAAC;AAAA;;;;"}
package/package.json ADDED
@@ -0,0 +1,22 @@
1
+ {
2
+ "name": "@x-oasis/is-ref",
3
+ "version": "0.0.16",
4
+ "description": "is-ref function",
5
+ "main": "dist/index.js",
6
+ "typings": "dist/index.d.ts",
7
+ "module": "dist/is-ref.esm.js",
8
+ "author": "",
9
+ "license": "ISC",
10
+ "devDependencies": {
11
+ "tsdx": "^0.14.1"
12
+ },
13
+ "dependencies": {
14
+ "@x-oasis/is-object": "^0.0.15"
15
+ },
16
+ "scripts": {
17
+ "build": "tsdx build --tsconfig tsconfig.build.json",
18
+ "clean": "rimraf ./dist",
19
+ "test": "vitest",
20
+ "compile": "tsc -p tsconfig.build.json"
21
+ }
22
+ }
package/src/index.ts ADDED
@@ -0,0 +1,3 @@
1
+ import isObject from '@x-oasis/is-object';
2
+
3
+ export default (obj: any) => isObject(obj) && obj['current'];
@@ -0,0 +1,5 @@
1
+ import { expect, test } from 'vitest';
2
+
3
+ test('vitest', async () => {
4
+ expect('vitest').toBe('vitest');
5
+ });
@@ -0,0 +1,11 @@
1
+ {
2
+ "extends": "../../../tsconfig.build.json",
3
+ "compilerOptions": {
4
+ "outDir": "./dist",
5
+ "esModuleInterop": true
6
+ },
7
+
8
+ "include": [
9
+ "src/**/*"
10
+ ]
11
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,7 @@
1
+ {
2
+ "extends": "../../../tsconfig.json",
3
+ "compilerOptions": {
4
+ "jsx": "react",
5
+ "esModuleInterop": true
6
+ }
7
+ }