Skip to content

chore: moved theme plugins into monorepo#10148

Draft
lizschwab wants to merge 2 commits into
RaspberryPiFoundation:mainfrom
lizschwab:7762
Draft

chore: moved theme plugins into monorepo#10148
lizschwab wants to merge 2 commits into
RaspberryPiFoundation:mainfrom
lizschwab:7762

Conversation

@lizschwab

Copy link
Copy Markdown
Contributor

The basics

The details

Resolves

Fixes #7762

Proposed Changes

Reason for Changes

Test Coverage

Documentation

Additional Information

In its current state themes will not build or run. If we update the blockly package.json exports to include the /dist folder in the front of the paths( see example below), the themes will build and run but blockly tests will fail and it would likely fail to resolve for anyone attempting to use the package if it were to be published that way.

Example of how to update packages/blockly/package.json:

  "exports": {
    ".": {
      "types": "./index.d.ts",
      "import": "./index.mjs",
      "umd": "./blockly.min.js",
      "default": "./index.js"
    },
    "./core": {
      "types": "./core.d.ts",
      "node": "./core-node.js",
      "import": "./blockly.mjs",
      "default": "./blockly_compressed.js"
    },
    "./blocks": {
      "types": "./blocks.d.ts",
      "import": "./blocks.mjs",
      "default": "./blocks_compressed.js"
    },
    "./dart": {
      "types": "./dart.d.ts",
      "import": "./dart.mjs",
      "default": "./dart_compressed.js"
    },
    "./lua": {
      "types": "./lua.d.ts",
      "import": "./lua.mjs",
      "default": "./lua_compressed.js"
    },
    "./javascript": {
      "types": "./javascript.d.ts",
      "import": "./javascript.mjs",
      "default": "./javascript_compressed.js"
    },
    "./php": {
      "types": "./php.d.ts",
      "import": "./php.mjs",
      "default": "./php_compressed.js"
    },
    "./python": {
      "types": "./python.d.ts",
      "import": "./python.mjs",
      "default": "./python_compressed.js"
    },
    "./msg/*": {
      "types": "./msg/*.d.ts",
      "import": "./msg/*.mjs",
      "default": "./msg/*.js"
    }
  },

A more detailed list of what does and does not work with each version of the blockly package.json:

Needs /dist in exports to work:

  • building themes
  • npm run start in themes

Needs exports as-is:

  • testing blockly

Works in both:

  • building blockly
  • building docs
  • linting blockly
  • linting docs
  • linting themes (except hackermode, which does not have a lint command)
  • testing docs
  • format (root level)

TODO

[ ] Resolve issue around /dist folder
[ ] Clarify what workspace-notation looks like for dependencies

@github-actions github-actions Bot added the PR: chore General chores (dependencies, typos, etc) label Jul 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR: chore General chores (dependencies, typos, etc)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pull theme plugins into the monorepo and test install/build/workflows

1 participant