@mherod/get-cookie 4.4.2 → 4.5.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.
Files changed (59) hide show
  1. package/README.md +26 -5
  2. package/dist/bun.cjs +77 -0
  3. package/dist/bun.cjs.map +1 -0
  4. package/dist/bun.d.cts +3 -0
  5. package/dist/bun.d.ts +3 -0
  6. package/dist/bun.js +77 -0
  7. package/dist/bun.js.map +1 -0
  8. package/dist/cli.cjs +14 -11
  9. package/dist/cli.cjs.map +1 -1
  10. package/dist/index.cjs +11 -11
  11. package/dist/index.cjs.map +1 -1
  12. package/dist/index.d.cts +103 -37
  13. package/dist/index.d.ts +103 -37
  14. package/dist/index.js +11 -11
  15. package/dist/index.js.map +1 -1
  16. package/dist/node.cjs +77 -0
  17. package/dist/node.cjs.map +1 -0
  18. package/dist/node.d.cts +3 -0
  19. package/dist/node.d.ts +3 -0
  20. package/dist/node.js +77 -0
  21. package/dist/node.js.map +1 -0
  22. package/dist/tsconfig.tsbuildinfo +1 -1
  23. package/package.json +32 -14
  24. package/.claude/settings.local.json +0 -3
  25. package/.dependency-cruiser.js +0 -277
  26. package/.env.example +0 -5
  27. package/.husky/commit-msg +0 -19
  28. package/.husky/pre-commit +0 -29
  29. package/.husky/pre-push +0 -21
  30. package/.idea/codeStyles/Project.xml +0 -59
  31. package/.idea/codeStyles/codeStyleConfig.xml +0 -5
  32. package/.idea/get-cookie.iml +0 -13
  33. package/.idea/git_toolbox_prj.xml +0 -15
  34. package/.idea/jsLibraryMappings.xml +0 -6
  35. package/.idea/modules.xml +0 -8
  36. package/.idea/prettier.xml +0 -9
  37. package/.idea/runConfigurations/build.xml +0 -12
  38. package/.idea/vcs.xml +0 -6
  39. package/.nvmrc +0 -1
  40. package/biome.json +0 -117
  41. package/commitlint.config.js +0 -12
  42. package/eslint.config.js +0 -255
  43. package/examples/README.md +0 -71
  44. package/examples/advanced-usage.ts +0 -56
  45. package/examples/auth-tokens.ts +0 -143
  46. package/examples/basic-usage.ts +0 -43
  47. package/examples/cli-examples.sh +0 -51
  48. package/examples/comprehensive-demo.ts +0 -202
  49. package/examples/curl-integration.sh +0 -311
  50. package/examples/features-demo.sh +0 -260
  51. package/examples/github-auth.sh +0 -295
  52. package/examples/quick-start.sh +0 -115
  53. package/jest.setup.js +0 -34
  54. package/tsconfig.build.json +0 -9
  55. package/tsconfig.cli.json +0 -16
  56. package/tsconfig.tsup.json +0 -12
  57. package/tsup.cli.ts +0 -59
  58. package/tsup.lib.ts +0 -46
  59. package/typedoc.json +0 -17
package/jest.setup.js DELETED
@@ -1,34 +0,0 @@
1
- const lodash = require("lodash");
2
-
3
- jest.mock("lodash-es", () => lodash);
4
- jest.mock("lodash-es/merge", () => require("lodash/merge"));
5
- jest.mock("lodash-es/memoize", () => require("lodash/memoize"));
6
- jest.mock("lodash-es/uniqBy", () => require("lodash/uniqBy"));
7
-
8
- // Create a mock logger that can be reused
9
- const mockLogger = {
10
- debug: jest.fn(),
11
- info: jest.fn(),
12
- success: jest.fn(),
13
- warn: jest.fn(),
14
- error: jest.fn(),
15
- fatal: jest.fn(),
16
- log: jest.fn(),
17
- withTag: jest.fn(),
18
- };
19
-
20
- mockLogger.withTag.mockReturnValue(mockLogger);
21
-
22
- // Mock the logger
23
- jest.mock("@utils/logger", () => mockLogger);
24
-
25
- // Mock logHelpers to ensure createTaggedLogger works
26
- jest.mock("@utils/logHelpers", () => ({
27
- createTaggedLogger: jest.fn(() => mockLogger),
28
- logError: jest.fn(),
29
- logOperationResult: jest.fn(),
30
- logWarn: jest.fn(),
31
- logger: mockLogger,
32
- }));
33
-
34
- // Add any other global setup here
@@ -1,9 +0,0 @@
1
- {
2
- "extends": "./tsconfig.json",
3
- "include": ["src/**/*", "jest.config.ts", "tsup.*.ts"],
4
- "exclude": ["node_modules", "dist", "**/__tests__/**", "**/__mocks__/**"],
5
- "compilerOptions": {
6
- "module": "ESNext",
7
- "moduleResolution": "bundler"
8
- }
9
- }
package/tsconfig.cli.json DELETED
@@ -1,16 +0,0 @@
1
- {
2
- "extends": "./tsconfig.json",
3
- "include": ["src/**/*"],
4
- "exclude": ["node_modules", "dist", "**/__tests__/**", "**/__mocks__/**"],
5
- "compilerOptions": {
6
- "module": "ESNext",
7
- "moduleResolution": "bundler",
8
- "composite": false,
9
- "declaration": true,
10
- "declarationMap": true,
11
- "strict": true,
12
- "noEmitOnError": true,
13
- "isolatedModules": true,
14
- "verbatimModuleSyntax": false
15
- }
16
- }
@@ -1,12 +0,0 @@
1
- {
2
- "extends": "./tsconfig.json",
3
- "include": ["src/**/*"],
4
- "exclude": ["node_modules", "dist", "**/__tests__/**", "**/__mocks__/**"],
5
- "compilerOptions": {
6
- "module": "ESNext",
7
- "moduleResolution": "bundler",
8
- "composite": false,
9
- "declaration": true,
10
- "declarationMap": true
11
- }
12
- }
package/tsup.cli.ts DELETED
@@ -1,59 +0,0 @@
1
- import { execSync } from "node:child_process";
2
-
3
- import { defineConfig } from "tsup";
4
-
5
- /**
6
- * Configuration for building the CLI bundle
7
- * @example
8
- * ```typescript
9
- * // Build the CLI bundle
10
- * import config from './tsup.cli';
11
- * await build(config);
12
- * ```
13
- */
14
- export default defineConfig({
15
- entry: ["src/cli/cli.ts"],
16
- format: ["cjs"],
17
- dts: {
18
- resolve: true,
19
- entry: ["src/cli/cli.ts"],
20
- compilerOptions: {
21
- strict: true,
22
- noEmitOnError: true,
23
- },
24
- },
25
- clean: false,
26
- sourcemap: true,
27
- minify: true,
28
- platform: "node",
29
- bundle: true,
30
- tsconfig: "./tsconfig.cli.json",
31
- noExternal: ["lodash-es"],
32
- external: ["bun:sqlite"],
33
- treeshake: true,
34
- splitting: false,
35
- skipNodeModulesBundle: true,
36
- esbuildOptions(options) {
37
- options.alias = {
38
- lodash: "lodash-es",
39
- };
40
- // Inject build timestamp at compile time
41
- const now = new Date();
42
- const timestamp = now.toISOString().replace("T", " ").slice(0, 19);
43
-
44
- // Try to get git branch name
45
- let gitBranch = "local";
46
- try {
47
- gitBranch = execSync("git rev-parse --abbrev-ref HEAD", {
48
- encoding: "utf8",
49
- }).trim();
50
- } catch {
51
- // Ignore git errors
52
- }
53
-
54
- options.define = {
55
- ...options.define,
56
- BUILD_TIMESTAMP: JSON.stringify(`${timestamp} UTC (${gitBranch})`),
57
- };
58
- },
59
- });
package/tsup.lib.ts DELETED
@@ -1,46 +0,0 @@
1
- import { defineConfig } from "tsup";
2
-
3
- /**
4
- * Configuration for building the library bundle
5
- * @example
6
- * ```typescript
7
- * // Build the library bundle
8
- * import config from './tsup.lib';
9
- * await build(config);
10
- * ```
11
- */
12
- export default defineConfig({
13
- entry: ["src/index.ts"],
14
- format: ["cjs", "esm"],
15
- dts: {
16
- resolve: true,
17
- entry: ["src/index.ts"],
18
- compilerOptions: {
19
- strict: true,
20
- noEmitOnError: true,
21
- },
22
- },
23
- clean: true,
24
- sourcemap: true,
25
- minify: true,
26
- platform: "node",
27
- bundle: true,
28
- tsconfig: "./tsconfig.tsup.json",
29
- external: [
30
- "fs",
31
- "path",
32
- "crypto",
33
- "os",
34
- "child_process",
35
- "lodash-es",
36
- "bun:sqlite",
37
- ],
38
- treeshake: true,
39
- splitting: false,
40
- skipNodeModulesBundle: true,
41
- esbuildOptions(options) {
42
- options.alias = {
43
- lodash: "lodash-es",
44
- };
45
- },
46
- });
package/typedoc.json DELETED
@@ -1,17 +0,0 @@
1
- {
2
- "$schema": "https://typedoc.org/schema.json",
3
- "entryPoints": ["src/index.ts", "src/cli/cli.ts"],
4
- "out": "docs/reference",
5
- "plugin": ["typedoc-plugin-markdown"],
6
- "readme": "none",
7
- "cleanOutputDir": true,
8
- "githubPages": false,
9
- "hideBreadcrumbs": true,
10
- "excludePrivate": true,
11
- "excludeProtected": true,
12
- "excludeExternals": true,
13
- "includeVersion": true,
14
- "categorizeByGroup": true,
15
- "categoryOrder": ["Core", "Browsers", "CLI", "*"],
16
- "tsconfig": "tsconfig.json"
17
- }