@imcms/core 0.0.0-stage → 1.0.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/dist/index.cjs ADDED
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
15
+
16
+ // src/index.ts
17
+ var index_exports = {};
18
+ module.exports = __toCommonJS(index_exports);
@@ -0,0 +1,23 @@
1
+ interface Logger {
2
+ warn: (message: string, ...items: unknown[]) => void;
3
+ debug: (message: string, ...items: unknown[]) => void;
4
+ info: (message: string, ...items: unknown[]) => void;
5
+ error: (message: string, ...items: unknown[]) => void;
6
+ }
7
+
8
+ interface DefaultParams {
9
+ debugMode?: boolean;
10
+ logger?: Logger;
11
+ }
12
+
13
+ type OperationResult<T = unknown> = {
14
+ message?: string;
15
+ item?: T;
16
+ status: "success";
17
+ } | {
18
+ message?: string;
19
+ error?: unknown;
20
+ status: "error";
21
+ };
22
+
23
+ export type { DefaultParams, Logger, OperationResult };
@@ -0,0 +1,23 @@
1
+ interface Logger {
2
+ warn: (message: string, ...items: unknown[]) => void;
3
+ debug: (message: string, ...items: unknown[]) => void;
4
+ info: (message: string, ...items: unknown[]) => void;
5
+ error: (message: string, ...items: unknown[]) => void;
6
+ }
7
+
8
+ interface DefaultParams {
9
+ debugMode?: boolean;
10
+ logger?: Logger;
11
+ }
12
+
13
+ type OperationResult<T = unknown> = {
14
+ message?: string;
15
+ item?: T;
16
+ status: "success";
17
+ } | {
18
+ message?: string;
19
+ error?: unknown;
20
+ status: "error";
21
+ };
22
+
23
+ export type { DefaultParams, Logger, OperationResult };
package/dist/index.js ADDED
File without changes
package/package.json CHANGED
@@ -1,6 +1,31 @@
1
1
  {
2
2
  "name": "@imcms/core",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
3
+ "version": "1.0.0",
4
+ "description": "",
5
+ "main": "index.js",
6
+ "publishConfig": {
7
+ "access": "public"
8
+ },
9
+ "keywords": [],
10
+ "author": "",
11
+ "license": "ISC",
12
+ "devEngines": {
13
+ "packageManager": {
14
+ "name": "pnpm",
15
+ "version": "12.15.0",
16
+ "onFail": "download"
17
+ }
18
+ },
19
+ "type": "module",
20
+ "devDependencies": {
21
+ "tsup": "^9.0.0",
22
+ "tsx": "^4.23.15",
23
+ "typescript": "^5.9.3"
24
+ },
25
+ "dependencies": {
26
+ "@types/node": "^26.6.5"
27
+ },
28
+ "scripts": {
29
+ "test": "echo \"Error: no test specified\" && exit 1"
30
+ }
6
31
  }
@@ -0,0 +1,2 @@
1
+ allowBuilds:
2
+ esbuild: true
@@ -0,0 +1,9 @@
1
+
2
+ // core/defaultParams.ts
3
+
4
+ import type{ Logger } from './logger.js';
5
+
6
+ export interface DefaultParams {
7
+ debugMode?: boolean
8
+ logger?: Logger
9
+ }
package/src/index.ts ADDED
@@ -0,0 +1,3 @@
1
+ export * from "./defaultParams.js"
2
+ export * from "./logger.js"
3
+ export * from "./operationResult.js"
package/src/logger.ts ADDED
@@ -0,0 +1,9 @@
1
+
2
+ // core/logger.ts
3
+
4
+ export interface Logger {
5
+ warn: (message: string, ...items: unknown[])=>void
6
+ debug: (message: string, ...items: unknown[])=>void
7
+ info: (message: string, ...items: unknown[])=>void
8
+ error: (message: string, ...items: unknown[])=>void
9
+ }
@@ -0,0 +1,3 @@
1
+ // core/operationResult.ts
2
+
3
+ export type OperationResult<T = unknown> = {message?: string, item?: T, status: "success"} | {message?: string, error?: unknown, status: "error"}
package/tsconfig.json ADDED
@@ -0,0 +1,44 @@
1
+ {
2
+ // Visit https://aka.ms/tsconfig to read more about this file
3
+ "compilerOptions": {
4
+ // File Layout
5
+ // "rootDir": "./src",
6
+ // "outDir": "./dist",
7
+
8
+ // Environment Settings
9
+ // See also https://aka.ms/tsconfig/module
10
+ "module": "nodenext",
11
+ "target": "esnext",
12
+ "types": [],
13
+ // For nodejs:
14
+ // "lib": ["esnext"],
15
+ // "types": ["node"],
16
+ // and npm install -D @types/node
17
+
18
+ // Other Outputs
19
+ "sourceMap": true,
20
+ "declaration": true,
21
+ "declarationMap": true,
22
+
23
+ // Stricter Typechecking Options
24
+ "noUncheckedIndexedAccess": true,
25
+ "exactOptionalPropertyTypes": true,
26
+
27
+ // Style Options
28
+ // "noImplicitReturns": true,
29
+ // "noImplicitOverride": true,
30
+ // "noUnusedLocals": true,
31
+ // "noUnusedParameters": true,
32
+ // "noFallthroughCasesInSwitch": true,
33
+ // "noPropertyAccessFromIndexSignature": true,
34
+
35
+ // Recommended Options
36
+ "strict": true,
37
+ "jsx": "react-jsx",
38
+ "verbatimModuleSyntax": true,
39
+ "isolatedModules": true,
40
+ "noUncheckedSideEffectImports": true,
41
+ "moduleDetection": "force",
42
+ "skipLibCheck": true,
43
+ }
44
+ }
package/README.md DELETED
@@ -1,3 +0,0 @@
1
- # Temporary Holding Version
2
-
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.