Skip to content

Comments

framework v4へ対応#50

Merged
ienaga merged 11 commits intomainfrom
develop
Feb 11, 2026
Merged

framework v4へ対応#50
ienaga merged 11 commits intomainfrom
develop

Conversation

@ienaga
Copy link
Member

@ienaga ienaga commented Feb 10, 2026

No description provided.

Copilot AI review requested due to automatic review settings February 10, 2026 06:27
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates @next2d/view-generator to support framework v4 by adjusting the generated View/ViewModel templates, raising the minimum Node.js recommendation, and bumping the package to v4.

Changes:

  • Update generated View/ViewModel templates to match the framework v4 lifecycle/constructor expectations.
  • Bump recommended Node version (18 → 22) and expand route name splitting to include _.
  • Release/tooling updates: package version to 4.0.0, dependency bumps, and GitHub Actions workflow adjustments (Node 24, publish flow changes).

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/index.ts Updates generator templates and Node version recommendation; adjusts routing key splitting.
package.json Major version bump to 4.0.0 and devDependency updates.
package-lock.json Lockfile updates to match dependency/version changes.
.github/workflows/publish.yml Updates publish job setup and changes npm publish/auth approach.
.github/workflows/lint.yml Updates CI Node/actions versions and npm setup steps.
Comments suppressed due to low confidence (1)

src/index.ts:13

  • pc.red(...) is called as a standalone expression, so the error message is never printed and it also violates the repo’s no-unused-expressions ESLint rule. Use console.log/console.error (or otherwise consume the string) so users see the message and lint passes.
const recommendeVersion: number = 22;
const version: string = process.versions.node;
if (recommendeVersion > parseInt(version.split(".")[0])) {
    pc.red(`You are running Node Version:${version}.
View Generator requires Node ${recommendeVersion} or higher.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 52 to +59
/**
* @param {${name}ViewModel} vm
* @constructor
* @public
*/
constructor ()
constructor (vm)
{
super();
super(vm);
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

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

In the generated JavaScript View template, the JSDoc references ${name}ViewModel but that symbol is not imported/defined in the file, so type-aware tooling will treat it as an unknown type. Consider using an inline import("./${name}ViewModel").${name}ViewModel JSDoc type (or add a type-only import pattern) so the annotation resolves without adding runtime coupling.

Copilot uses AI. Check for mistakes.
Comment on lines 8 to 24
permissions:
id-token: write
contents: read

jobs:
build:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v5
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version: "22.x"
node-version: 24
registry-url: "https://registry.npmjs.org"
- run: npm install -g npm@latest
- run: npm install
- run: npm run release
- run: npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} No newline at end of file
- run: npm publish No newline at end of file
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

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

The publish workflow no longer provides an npm auth token (e.g., NODE_AUTH_TOKEN) but still runs npm publish. Unless this repo/package is configured for npm Trusted Publishing via OIDC, this will fail. Either restore token-based auth, or update the workflow to use the intended OIDC/trusted publishing flow (and keep only the minimum required permissions).

Copilot uses AI. Check for mistakes.
@ienaga ienaga merged commit 7aad239 into main Feb 11, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant