Skip to content

Conversation

@uzmoi
Copy link
Member

@uzmoi uzmoi commented Jan 6, 2025

Close #12

いらないバージョンを読み込まなくて良いようにdynamic importをしている。
<select />で選ぶようにしたが、/// @ 0.19.0の形式のコメントにも対応したい。

@kakkokari-gtyih
Copy link
Collaborator

draftだけど動作することを確認したのでapprove

@uzmoi
Copy link
Member Author

uzmoi commented Jan 7, 2025

/// @ 0.19.0のコメントは↓を書けば動きはしたが、コード入力中にローディングが挟まってエディタからフォーカスが外れるため見送り。

watch(code, (newCode, oldCode) => {
    const newCodeVersion = utils.getLangVersion(newCode);
    if (
        newCodeVersion != null &&
        versionModules.has(newCodeVersion) &&
        newCodeVersion !== utils.getLangVersion(oldCode)
    ) {
        version.value = newCodeVersion;
    }
});

@uzmoi uzmoi marked this pull request as ready for review January 7, 2025 16:35
@kakkokari-gtyih kakkokari-gtyih merged commit 9dc3321 into aiscript-dev:main Jan 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Playgroundページの複数バージョン対応

2 participants