HTML parser lowercases tag names that collide with native HTML elements (affects Svelte/Vue)

オープン
#382 コメント 1 件 リアクション 2 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
58/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
静か
技術スタック
html, typescript
領域
frontend, web-dev

調査の方向性

Start by locating the @figma/code-connect/html tagged-template parser and trace where it lowercases native element names. Compare handling of Select and Textarea with TextField using the issue’s examples. Done means component names that collide with native HTML elements retain PascalCase in the generated output while native lowercase tags remain unchanged.

索引モデルが issue の本文から書いたものです。

説明

feature request

Feature Request

The html tagged template from @figma/code-connect/html lowercases tag names that match native HTML elements (e.g., <Select>, <Textarea>), while custom element names like <TextField> preserve their PascalCase.

For frameworks like Svelte and Vue, <Select> and <select> are semantically different — the former is a component, the latter is a native element.

Current output: <select bind:value />
Desired output: <Select bind:value />

Note: Non-native tag names like <TextField> correctly preserve PascalCase.

Use Case

We use Code Connect with parser: "html" and label: "Svelte" for our Svelte 5 design system. Components named Select and Textarea display as native HTML elements in the Dev Mode code panel, which is confusing for developers.

Environment

  • @figma/code-connect v1.4.2
  • figma.config.json: { "parser": "html", "label": "Svelte" }
主要言語
TypeScript
スター
1.6k
フォーク
126
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

figma/code-connect のほかの issue

figma/code-connect の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。