@dyanet/nextjs-config-aws 1.1.1 → 1.1.2

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 ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Dyanet
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -28,6 +28,9 @@ npm install @dyanet/nextjs-config-aws
28
28
  npm install next react
29
29
  ```
30
30
 
31
+ Supports **Next.js `>=14`** and **React `>=18`** (App Router). Developed and tested against
32
+ the latest Next.js and React.
33
+
31
34
  For AWS services, install the SDK clients you need:
32
35
 
33
36
  ```bash
@@ -0,0 +1,3 @@
1
+ {
2
+ "type": "commonjs"
3
+ }
@@ -4,5 +4,5 @@
4
4
  * These utilities are designed for use in client components ('use client')
5
5
  * to access runtime environment variables injected by PublicEnvScript.
6
6
  */
7
- export { env, envFrom, getAllEnv, hasEnv } from './env';
7
+ export { env, envFrom, getAllEnv, hasEnv } from './env.js';
8
8
  //# sourceMappingURL=index.js.map
@@ -1,5 +1,5 @@
1
1
  /**
2
2
  * Client-side components for Next.js configuration management.
3
3
  */
4
- export { PublicEnvScript, filterEnvVars, generateScriptContent, } from './public-env-script';
4
+ export { PublicEnvScript, filterEnvVars, generateScriptContent, } from './public-env-script.js';
5
5
  //# sourceMappingURL=index.js.map
package/dist/esm/index.js CHANGED
@@ -48,9 +48,9 @@
48
48
  // Error classes for error handling
49
49
  export { ConfigurationError, ValidationError } from '@dyanet/config-aws';
50
50
  // Server-side configuration loading
51
- export { getConfig } from './server';
51
+ export { getConfig } from './server/index.js';
52
52
  // Component for runtime environment variables
53
- export { PublicEnvScript } from './components';
53
+ export { PublicEnvScript } from './components/index.js';
54
54
  // Client-side environment variable access
55
- export { env } from './client';
55
+ export { env } from './client/index.js';
56
56
  //# sourceMappingURL=index.js.map
@@ -1 +1,3 @@
1
- {"type":"module"}
1
+ {
2
+ "type": "module"
3
+ }
@@ -28,8 +28,8 @@
28
28
  * ```
29
29
  */
30
30
  import { ConfigManager, } from '@dyanet/config-aws';
31
- import { detectEnvironment } from './internal/environment';
32
- import { createLoaders } from './internal/loader-factory';
31
+ import { detectEnvironment } from './internal/environment.js';
32
+ import { createLoaders } from './internal/loader-factory.js';
33
33
  /**
34
34
  * Cache storage for configuration
35
35
  * Uses a Map to support multiple cache keys (for different option combinations)
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Server-side exports for Next.js configuration management.
3
3
  */
4
- export { getConfig, clearConfigCache, getConfigCacheSize, invalidateConfig, } from './get-config';
5
- export { createConfigProvider, ConfigProvider, useConfig, ConfigContext, } from './config-provider';
4
+ export { getConfig, clearConfigCache, getConfigCacheSize, invalidateConfig, } from './get-config.js';
5
+ export { createConfigProvider, ConfigProvider, useConfig, ConfigContext, } from './config-provider.js';
6
6
  //# sourceMappingURL=index.js.map
@@ -3,6 +3,6 @@
3
3
  * These are not exported from the public API.
4
4
  * @internal
5
5
  */
6
- export { detectEnvironment } from './environment';
7
- export { createLoaders } from './loader-factory';
6
+ export { detectEnvironment } from './environment.js';
7
+ export { createLoaders } from './loader-factory.js';
8
8
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dyanet/nextjs-config-aws",
3
- "version": "1.1.1",
3
+ "version": "1.1.2",
4
4
  "description": "Next.js adapter for AWS configuration management with support for server components, runtime environment variables, and AWS services integration",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -18,10 +18,11 @@
18
18
  "LICENSE"
19
19
  ],
20
20
  "scripts": {
21
- "build": "npm run clean && npm run build:types && npm run build:esm && npm run build:cjs",
21
+ "build": "npm run clean && npm run build:types && npm run build:esm && npm run build:cjs && npm run build:postbuild",
22
22
  "build:types": "tsc --project tsconfig.types.json",
23
- "build:esm": "tsc --project tsconfig.esm.json && echo {\"type\":\"module\"} > dist/esm/package.json",
23
+ "build:esm": "tsc --project tsconfig.esm.json",
24
24
  "build:cjs": "tsc --project tsconfig.cjs.json",
25
+ "build:postbuild": "node ../../scripts/postbuild.mjs ./dist",
25
26
  "clean": "rimraf dist",
26
27
  "test": "jest",
27
28
  "test:watch": "jest --watch",
@@ -60,8 +61,8 @@
60
61
  "@dyanet/config-aws": "^1.0.0"
61
62
  },
62
63
  "peerDependencies": {
63
- "next": "^16.0.0",
64
- "react": "^19.0.0"
64
+ "next": ">=14.0.0",
65
+ "react": ">=18.0.0"
65
66
  },
66
67
  "devDependencies": {
67
68
  "@aws-sdk/client-s3": "^3.0.0",