-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Review contents of blockly.js
#5208
Labels
Milestone
Comments
rachel-fenichel
added
issue: feature request
Describes a new feature and why it should be added
issue: triage
Issues awaiting triage by a Blockly team member
type: cleanup
and removed
issue: triage
Issues awaiting triage by a Blockly team member
issue: feature request
Describes a new feature and why it should be added
labels
Jul 24, 2021
@cpcallen This is obviously incomplete, but is a place to start in on pulling apart |
12 tasks
This was referenced Jul 28, 2021
Breaking out parts of the remaining work:
|
This was referenced Sep 13, 2021
This was referenced Sep 16, 2021
5 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
blockly.js
is full of public stuff that doesn't really fit on any namespace. This is a problem because internal code requiring it causes circular dependencies.The fix is to move everything in
blockly.js
out into separate files and require those from inside the codebase, while leaving aliases behind inblockly.js
for anything that should stay publicly accessible.In some cases, we also need setters so that external code can change those values.
In other cases, properties should just not be exported.
This issue is for tracking decisions about these properties and whether those decisions have been implemented.
Needs decision:
hideChaff
alert
confirm
prompt
hueToHex
Can be internal:
Blockly.jsonInitFactory_
clipboardXml_
->clipboard.js
in Move clipboard functions to a separate namespace #5237clipboardSource_
->clipboard.js
in Move clipboard functions to a separate namespace #5237clipboardTypeCounts_
->clipboard.js
in Move clipboard functions to a separate namespace #5237parentContainer
->common.js
in More cleanup of blockly.js #5262draggingConnections
->common.js
in More cleanup of blockly.js #5262onKeyDown
->inject.js
in refactor: Migrate Blockly.onKeyDown out of blockly.js #5476Exported function, but moved to a different file and aliased.
bindEvent_
->Blockly.browserEvents.bind
in Move bind/unbind events functions to new file, with example usage. #4642 (2021Q1)getMainWorkspace
->Blockly.common.getMainWorkspace
in Move main workspace to a new file, common.js #5244copy
->Blockly.clipboard.copy
in Move clipboard functions to a separate namespace #5237, and tracking remaining work in Keyboard nav uses non-public properties in paste blockly-samples#833paste ->
Blockly.clipboard.paste` in Move clipboard functions to a separate namespace #5237, and tracking remaining work in Keyboard nav uses non-public properties in paste blockly-samples#833duplicate
->Blockly.clipboard.duplicate
in Move clipboard functions to a separate namespace #5237, and tracking remaining work in Keyboard nav uses non-public properties in paste blockly-samples#833setParentContainer
->Blockly.common.setParentContainer
in More cleanup of blockly.js #5262hueToHex
->Blockly.utils.colour.hueToHex
in Migrate Blockly.hueToHex to Blockly.utils.colour.hueToHex #5462alert
->Blockly.dialog.alert
in Move alert/confirm/prompt to a new file, dialog.js #5457confirm
->Blockly.dialog.confirm
in Move alert/confirm/prompt to a new file, dialog.js #5457prompt
->Blockly.dialog.prompt
in Move alert/confirm/prompt to a new file, dialog.js #5457deleteBlock
->Blockly.BlockSvg.checkAndDelete
in refactor: move Blockly.deleteBlock out of blockly.js #5483svgResize
->Blockly.common.svgResize
in refactor: Move Blockly.svgResize to Blockly.common #5485Exported function, used only externally and therefore left in
blockly.js
:isNumber
: Used in generatorsdefineBlocksWithJsonArray
: Used in block definitionssvgSize
: Deprecated already, and marked for removal in March 2022resizeSvgContents
Exported read-only property:
Exported settable property:
mainWorkspace
in Move main workspace to a new file, common.js #5244, with a follow-up to add deprecation warnings.Can be removed:
checkBlockColourConstants
: Only used internally, and as a deprecation helper for an old deprecation. Deleted in More cleanup of blockly.js #5262.checkBlockColourConstant_
: Only used by `checkBlockColourConstants. Deleted in More cleanup of blockly.js #5262.cache3dSupported_
: Not used. Deleted in More cleanup of blockly.js #5262.onContextMenu_
: Not used. Deleted in refactor: remove unused Blockly.onContextMenu_ #5480.The text was updated successfully, but these errors were encountered: