-
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
fix: advanced playground and playground #6021
Conversation
document.write('<script src="../../php_compressed.js"></script>'); | ||
document.write('<script src="../../python_compressed.js"></script>'); | ||
for (let i = 0; i < files.length; i++) { | ||
document.write('<script src="/' + root + files[i] + '"></script>'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For future: this seems like a good example of a place to use template strings
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So when writing this PR I remembered that we probably want at least the basic playground to work on ie11 to make testing easier. I don't think it currently will, but I didn't want to add another piece that we would have to go back and update.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ohhh gotcha gotcha. Sweet! That makes sense
goog.require('Blockly.libraryBlocks'); | ||
goog.require('Blockly.Dart.all'); | ||
goog.require('Blockly.JavaScript.all'); | ||
goog.require('Blockly.Lua.all'); | ||
goog.require('Blockly.PHP.all'); | ||
goog.require('Blockly.Python.all'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think these should be bundled in by goog.bootstrap
in prepare.js, could you check if these can be removed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good call. I can remove those as well as the minimalist renderer and the zelos themes because it looks like those are getting exported in blockly.js.
const TestHatsTheme = Blockly.Theme.defineTheme('testhats', { | ||
'base': Blockly.Themes.Classic | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This has side effects right? And that's how we can access the theme later? Just want to clarify.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this has side effects. We register themes in their constructors. However, I believe in this case the populateTestThemes
method is how we are adding the themes to the advanced playground.
The basics
npm run format
andnpm run lint
The details
Resolves
#6019 and the fact that the playground was not working when hosted.
Proposed Changes
Behavior Before Change
Behavior After Change
google.github.io
.Reason for Changes
Test Coverage
google.github.io
Documentation
Additional Information