Skip to content
Open
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
1 change: 1 addition & 0 deletions icons/b10cks.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 17 additions & 0 deletions modules/b10cks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: b10cks CMS
description: b10cks CMS Nuxt module
repo: b10cks/sdk#main/packages/nuxt
npm: '@b10cks/nuxt'
icon: b10cks.png
github: https://github.com/b10cks/sdk
website: https://github.com/b10cks/sdk/tree/main/packages/nuxt
learn_more: ''
category: CMS
type: 3rd-party
maintainers:
- name: b10cks
github: b10cks
compatibility:
nuxt: ^4.0.0
requires: {}
devtools: ^0.0.0
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 | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "1) Check how devtools compatibility is represented across manifests:"
rg -n "^[[:space:]]*devtools:" modules

echo
echo "2) Check if '^0.0.0' appears elsewhere:"
rg -n "^[[:space:]]*devtools:[[:space:]]*\\^0\\.0\\.0$" modules

echo
echo "3) Inspect compatibility evaluation logic in code:"
rg -n -C3 "devtools|semver|satisf" lib

Repository: nuxt/modules

Length of output: 5804


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== 1) Find where devtools compatibility field is actually used ==="
rg -n "\.devtools|compatibility\.devtools|devtools\?" lib --type ts

echo
echo "=== 2) Check what semver.minVersion('^0.0.0') would resolve to ==="
node <<'EOF'
const semver = require('semver');
const range = '^0.0.0';
try {
  const valid = semver.validRange(range);
  const minVer = semver.minVersion(range);
  const testVersion = '0.0.0';
  const satisfies = semver.satisfies(testVersion, range);
  console.log(`Range: ${range}`);
  console.log(`Valid: ${valid}`);
  console.log(`MinVersion: ${minVer}`);
  console.log(`Does 0.0.0 satisfy ${range}? ${satisfies}`);
  console.log(`Does 1.0.0 satisfy ${range}? ${semver.satisfies('1.0.0', range)}`);
} catch(e) {
  console.error(e.message);
}
EOF

echo
echo "=== 3) Search for any conditions checking against devtools versions ==="
rg -n -C5 "devtools" lib --type ts | head -100

Repository: nuxt/modules

Length of output: 1100


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== 1) Check all references to devtools in codebase ==="
rg -n "devtools" --type ts --type js --type json --type yml 

echo
echo "=== 2) Find ModuleCompatibility usage ==="
rg -n "ModuleCompatibility" lib --type ts -A 3 -B 1

echo
echo "=== 3) Check package.json for semver version ==="
cat package.json | grep -A2 '"semver"'

echo
echo "=== 4) Look for any validation or comparison of compatibility object ==="
rg -n "compatibility\[|compatibility\." lib --type ts -C 2

Repository: nuxt/modules

Length of output: 158


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== 1) Check all references to devtools in codebase ==="
rg -n "devtools" --type ts --type js --type json

echo
echo "=== 2) Find ModuleCompatibility usage ==="
rg -n "ModuleCompatibility" lib --type ts -A 3 -B 1

echo
echo "=== 3) Check package.json for semver version ==="
cat package.json | grep -A2 '"semver"'

echo
echo "=== 4) Look for any validation or comparison of compatibility object ==="
rg -n "compatibility\[|compatibility\." lib --type ts -C 2

Repository: nuxt/modules

Length of output: 1588


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== 1) Check what's exported from lib/index.ts or main entry ==="
find lib -name "index.ts" -o -name "index.js" | head -5
if [ -f "lib/index.ts" ]; then
  cat lib/index.ts
fi

echo
echo "=== 2) Check for any README or documentation ==="
cat README.md 2>/dev/null | head -100

echo
echo "=== 3) Look for devtools in tests or examples ==="
find . -name "*.test.*" -o -name "*.spec.*" | head -10
rg "devtools" --type ts --type js 2>/dev/null | grep -i "test\|spec" || echo "No devtools references in tests"

echo
echo "=== 4) Check if ModuleCompatibility is exported ==="
cat lib/types.ts | grep -E "^export|^import"

Repository: nuxt/modules

Length of output: 4105


Remove the unused devtools field or document its intended purpose.

The devtools field in ModuleCompatibility is never read or evaluated in the codebase—only the nuxt field is processed. Since this field is exported in the public API but completely unused internally, it should be removed entirely. If it's intended for future use or external consumption, it should be properly documented and initialized with a meaningful version. Currently, ^0.0.0 across 24 modules is a misleading placeholder that suggests incomplete implementation.

Proposed fix
 compatibility:
   nuxt: ^4.0.0
   requires: {}
-  devtools: ^0.0.0
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
devtools: ^0.0.0
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@modules/b10cks.yml` at line 17, The ModuleCompatibility export contains an
unused field devtools set to "^0.0.0"; remove the devtools property from the
ModuleCompatibility type and all module metadata entries (or, if it must stay
for external use, replace the placeholder with a documented, meaningful version
and add JSDoc explaining its purpose), and update any public API/export that
exposes ModuleCompatibility to no longer include devtools; search for the symbol
"devtools" and the type "ModuleCompatibility" to remove references, and ensure
the code path that processes "nuxt" remains unchanged.

Loading