Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions .changeset/lemon-trams-mix.md

This file was deleted.

13 changes: 13 additions & 0 deletions packages/browser/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# @asgardeo/browser

## 0.7.2

### Patch Changes

- [#483](https://github.com/asgardeo/javascript/pull/483)
[`519fa74`](https://github.com/asgardeo/javascript/commit/519fa746c2dace5446368ad9043e3aec0d152514) Thanks
[@kavindadimuthu](https://github.com/kavindadimuthu)! - Fix SSR compatibility and module bundling issues

- **Browser:** Fixed Node.js ESM import resolution by changing directory imports (`'buffer/'`) to explicit file paths
(`'buffer/index.js'`)
- **Nuxt:** Fixed Rollup bundling by centralizing module augmentations in `module.ts` and removing `.d.ts` file from
dist
Comment on lines +11 to +14
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Verify whether directory-style buffer imports still exist.
rg -nP --type=ts --type=tsx --type=js --type=mjs --type=cjs "from\\s+['\"]buffer/['\"]|require\\(\\s*['\"]buffer/['\"]\\s*\\)"

# Inspect web.worker.ts if present.
fd -i "web.worker.ts" | xargs -r -I{} sh -c "echo '--- {}'; nl -ba {} | sed -n '1,60p'"

# Expected result:
# - If matches exist, changelog wording should be narrowed or source imports should be updated.
# - If no matches, this comment can be dismissed.

Repository: asgardeo/javascript

Length of output: 91


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Verify whether directory-style buffer imports still exist (corrected flags)
echo "=== Searching for buffer/ directory imports ==="
rg -nP "from\s+['\"]buffer/['\"]|require\(\s*['\"]buffer/['\"]" --type ts --type js

echo -e "\n=== Looking for web.worker.ts ==="
fd "web.worker.ts" -exec cat -n {} \;

echo -e "\n=== Checking CHANGELOG.md context ==="
fd "CHANGELOG.md" packages/browser -exec sed -n '1,20p' {} \;

Repository: asgardeo/javascript

Length of output: 465


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== All buffer import occurrences ==="
rg "from\s+['\"]buffer" packages/browser/src/ -A 1 -B 1

echo -e "\n=== Checking web.worker.ts full content ==="
cat packages/browser/src/web.worker.ts

echo -e "\n=== CHANGELOG.md full entry (lines 11-14) ==="
sed -n '11,14p' packages/browser/CHANGELOG.md

echo -e "\n=== Check if there are bundle/rollup config files ==="
fd -e "rollup" -e "webpack" -e "tsconfig" -e "build" packages/browser

Repository: asgardeo/javascript

Length of output: 3097


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== Search for 'buffer/index.js' imports (claimed in changelog) ==="
rg "buffer/index\.js" packages/browser/ || echo "No matches found"

echo -e "\n=== Looking for build/bundler config files ==="
fd . packages/browser --type f | grep -E "(esbuild|rollup|webpack|tsconfig|build)" | head -20

echo -e "\n=== Check build or config files in packages/browser root ==="
ls -la packages/browser/ | grep -E "\.(ts|js|json|config)" || echo "No config files in root"

echo -e "\n=== Searching for esbuild configuration ==="
fd -e "ts" -e "js" -e "json" . packages/browser --type f | xargs rg -l "esbuild|Buffer" | head -10

Repository: asgardeo/javascript

Length of output: 1547


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== Examine esbuild.config.mjs ==="
cat packages/browser/esbuild.config.mjs

echo -e "\n=== Verify no buffer/index.js in source files ==="
rg "buffer/index\.js" packages/browser/src/ || echo "Confirmed: No buffer/index.js in source code"

Repository: asgardeo/javascript

Length of output: 3024


Changelog entry overstates the scope of the import fix.

The changelog claims directory imports were changed to explicit 'buffer/index.js' paths, but source code still contains import {Buffer} from 'buffer/'; in packages/browser/src/web.worker.ts. The actual fix is at the bundler level only (esbuild plugin aliasing buffer to 'buffer/index.js' and banner/footer setup), not source code. Update the changelog to clarify: "Fixed Node.js ESM import resolution via esbuild polyfill plugin" or similar, rather than implying source imports were changed.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/browser/CHANGELOG.md` around lines 11 - 14, Update the CHANGELOG
entry to avoid implying source imports were modified: replace the phrase about
changing directory imports to 'buffer/index.js' with a concise note that the
Node.js ESM import resolution was fixed via the esbuild polyfill/aliasing (the
bundler plugin that maps imports like "buffer/" to "buffer/index.js" and injects
the banner/footer), and mention that source files (e.g., import {Buffer} from
'buffer/'; in packages/browser/src/web.worker.ts) were left unchanged.


## 0.7.1

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/browser/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@asgardeo/browser",
"version": "0.7.1",
"version": "0.7.2",
"description": "Browser-specific implementation of Asgardeo JavaScript SDK.",
"keywords": [
"asgardeo",
Expand Down
7 changes: 7 additions & 0 deletions packages/nextjs/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# @asgardeo/nextjs

## 0.3.14

### Patch Changes

- Updated dependencies []:
- @asgardeo/react@0.23.3

## 0.3.13

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/nextjs/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@asgardeo/nextjs",
"version": "0.3.13",
"version": "0.3.14",
"description": "Next.js implementation of Asgardeo JavaScript SDK.",
"keywords": [
"asgardeo",
Expand Down
18 changes: 18 additions & 0 deletions packages/nuxt/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,23 @@
# @asgardeo/nuxt

## 0.1.2

### Patch Changes

- [#483](https://github.com/asgardeo/javascript/pull/483)
[`519fa74`](https://github.com/asgardeo/javascript/commit/519fa746c2dace5446368ad9043e3aec0d152514) Thanks
[@kavindadimuthu](https://github.com/kavindadimuthu)! - Fix SSR compatibility and module bundling issues

- **Browser:** Fixed Node.js ESM import resolution by changing directory imports (`'buffer/'`) to explicit file paths
(`'buffer/index.js'`)
- **Nuxt:** Fixed Rollup bundling by centralizing module augmentations in `module.ts` and removing `.d.ts` file from
dist

- Updated dependencies
[[`519fa74`](https://github.com/asgardeo/javascript/commit/519fa746c2dace5446368ad9043e3aec0d152514)]:
- @asgardeo/browser@0.7.2
- @asgardeo/vue@0.3.5

## 0.1.1

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/nuxt/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@asgardeo/nuxt",
"version": "0.1.1",
"version": "0.1.2",
"description": "Nuxt module for Asgardeo - Authentication and Identity Management",
"author": "WSO2",
"license": "Apache-2.0",
Expand Down
8 changes: 8 additions & 0 deletions packages/react/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# @asgardeo/react

## 0.23.3

### Patch Changes

- Updated dependencies
[[`519fa74`](https://github.com/asgardeo/javascript/commit/519fa746c2dace5446368ad9043e3aec0d152514)]:
- @asgardeo/browser@0.7.2

## 0.23.2

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/react/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@asgardeo/react",
"version": "0.23.2",
"version": "0.23.3",
"description": "React implementation of Asgardeo JavaScript SDK.",
"keywords": [
"asgardeo",
Expand Down
8 changes: 8 additions & 0 deletions packages/vue/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# @asgardeo/vue

## 0.3.5

### Patch Changes

- Updated dependencies
[[`519fa74`](https://github.com/asgardeo/javascript/commit/519fa746c2dace5446368ad9043e3aec0d152514)]:
- @asgardeo/browser@0.7.2

## 0.3.4

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/vue/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@asgardeo/vue",
"version": "0.3.4",
"version": "0.3.5",
"description": "Vue 3 SDK for Asgardeo - Authentication and Identity Management",
"keywords": [
"asgardeo",
Expand Down