vsce-toolroom / vscode-textmate-languageservice

Language APIs and support features from Textmate tokenization in Visual Studio Code.
Other
16 stars 0 forks source link

[icebox] Implement builtin streaming loader for WASM from data URI #16

Open zm-cttae opened 1 year ago

zm-cttae commented 1 year ago

⚡️️ Feature Request

Is your feature request related to a problem?

Streaming WASM compilation is 20-40 times faster than non-streaming. We will basically be killing most perf costs with this change.

Describe the solution you'd like

Create webpack plugin to inline as data URI then fetch as WASM. (This is blocked by Node 18.x adoption in VS Code.)

Describe alternatives you've considered

Ship with node-fetch which would mean an even bigger bundle size..

zm-cttae commented 1 year ago

changed due date to February 01, 2024

zm-cttae commented 1 year ago

marked the checklist item I'm using the latest version of vscode-textmate-languageservice available. as completed

zm-cttae commented 1 year ago

marked the checklist item I searched [existing issues][vsctmls-issues], open & closed. Yes, my feature request is new. as completed

zm-cttae commented 1 year ago

removed due date

zm-cttae commented 1 year ago

changed due date to February 01, 2024

zm-cttae commented 1 year ago

Upstream issue is microsoft/vscode#184021. Landing July or August.

changed due date to October 01, 2023

zm-cttae commented 3 weeks ago
Refused to connect to 'data:application/wasm;base64,' because it violates the following Content Security Policy directive: "connect-src 'self' https: wss: http://localhost:* http://127.0.0.1:* ws://localhost:* ws://127.0.0.1:*".

    <meta http-equiv="Content-Security-Policy" content="
        upgrade-insecure-requests;
        block-all-mixed-content;
        default-src 'none';
        base-uri 'self';
        manifest-src
            'self'
            https://vscodeweb.azureedge.net/
            https://main.vscode-cdn.net/
            https://github.dev/
        https://assets.github.dev/
        ;
        style-src
            'self'
            'unsafe-inline'
            https://vscodeweb.azureedge.net/
            https://main.vscode-cdn.net/
            https://*.vscode-unpkg.net/
            https://github.dev/
        https://assets.github.dev/
        ;
        img-src
            'self'
            https:
            data:
            blob:
            vscode-remote-resource:
            https://github.dev/
        https://assets.github.dev/
        ;
        connect-src
            'self'
        https://assets.github.dev/
            https://*.rel.tunnels.api.visualstudio.com
        wss://*.tunnels.api.visualstudio.com/
            http://*.dev.core.vsengsaas.visualstudio.com
                https://*.gallerycdn.vsassets.io
                https://vortex.data.microsoft.com/collect/v1
                https://vscode-sync.trafficmanager.net/
                https://vscode-sync-insiders.trafficmanager.net/
                https://vscode-sync-test.trafficmanager.net/
                https://marketplace.visualstudio.com/_apis/public/gallery/
                https://az764295.vo.msecnd.net/experiments/vscode-experiments.json
                https://vscodeexperiments.azureedge.net/experiments/vscode-experiments.json
                https://vscodeweb.azureedge.net/insider/
                https://vscodeweb.azureedge.net/stable/
                https://main.vscode-cdn.net/insider/
                https://main.vscode-cdn.net/stable/
                https://default.exp-tas.com/vscode/ab
                https://code.visualstudio.com/raw/
                https://vscode-auth.github.com
                https://*.gallery.vsassets.io/_apis/public/gallery/
                https://*.vscode-unpkg.net/
                https://github-cloud.githubusercontent.com/alambic/media/
                https://bingsettingssearch.trafficmanager.net/
                https://vscode.search.windows.net/
                https://vscode.blob.core.windows.net/gallery/index/
                https://marketplace.visualstudio.com/items/
                https://az764295.vo.msecnd.net/extensions/marketplace.json
                https://az764295.vo.msecnd.net/extensions/workspaceRecommendations.json.gz
                https://*.review-lab.github.com
                https://update.code.visualstudio.com/api/
                https://mobile.events.data.microsoft.com/
                https://az764295.vo.msecnd.net/profile-templates/
                https://vscode.download.prss.microsoft.com/
            https://api.github.com/
        ;
        font-src
            'self'
            https://main.vscode-cdn.net/insider/
            https://main.vscode-cdn.net/stable/
            https://vscodeweb.azureedge.net/insider/
            https://vscodeweb.azureedge.net/stable/
            https://*.vscode-unpkg.net/
            vscode-remote-resource:
            https://github.dev/
        https://assets.github.dev/
        ;
        frame-src
            'self'
            https://*.webview.codespaces.githubusercontent.com/webview/
        https://*.assets.github.dev/
            https://*.vscode-webview-test.com
                https://*.vscode-webview.net
                https://*.vscode-cdn.net/
                https://vscodeweb.azureedge.net/
        ;
        media-src
            https://assets.github.dev/
        ;
        worker-src
            https://github.dev/service-worker.js
        blob:
        ;
        child-src
            https://github.dev/service-worker.js
            blob:
        ;
        require-trusted-types-for
            'script'
        ;
        script-src
            'self'
            'unsafe-eval'
            https://vscodeweb.azureedge.net/
            https://main.vscode-cdn.net/
            https://www.vscode-unpkg.net/nls/
            https://github.dev/
        https://assets.github.dev/
        ;
        trusted-types
            default
            dompurify
            TrustedFunctionWorkaround
            ExtensionScripts
            amdLoader
            cellRendererEditorText
            defaultWorkerFactory
            diffEditorWidget
            editorGhostText
            domLineBreaksComputer
            editorViewLayer
            diffReview
            extensionHostWorker
            insane
            notebookRenderer
            safeInnerHtml
            standaloneColorizer
            tokenizeToString
            webNestedWorkerExtensionHost
            webWorkerExtensionHost
            stickyScrollViewLayer
        ;
    "/>