Skip to content

Snippets generated even when not needed #3330

Closed
@daxpedda

Description

@daxpedda

The PR #3069 introduced linked modules, link_to!(module = "/test.js"). Currently this is meant to use snippets only if the --split-linked-modules is enabled, but not otherwise.

Currently, snippets are always generated, even in the no-modules target, they can be safely deleted and ignored, but they shouldn't be generated in the first place.

This can be easily tried by using link_to!(module = "/test.js") and trying out the following commands.

  • wasm-bindgen --target no-modules
  • wasm-bindgen --target web
  • wasm-bindgen --target no-modules --split-linked-modules

Happy to give a more comprehensive, easy to use example if desired.

Cc @lukaslihotzki.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions