-
-
Notifications
You must be signed in to change notification settings - Fork 589
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
[WIP] Convert imports and exports to ES6 #1121
Closed
Closed
Commits on Dec 16, 2019
-
Convert imports and exports to ES6
The old `module.exports` syntax doesn't work downstream in the react-sdk or riot-web layers anymore, so this brings it up to 2019 standards. We do not use default exports anymore because they are discouraged by the ES6 community. It's not an official recommendation, but it's certainly commonplace. This also changes browser-index.js and index.js to use the `src` tree instead of `lib`. This is primarily to have IDEs autocomplete the package more easily, and because we're compiling this all in the riot-web layer it doesn't really matter. We still export `lib` and `dist/browser-matrix.js` for backwards compatibility (ie: everyone who has imported from `matrix-js-sdk/lib/whatever` or uses `<script>` tags). In a future version/PR we could drop these if we feel like it. This commit does not address the test failures that are almost certainly caused by this change. While we're here, the ancient `"use strict";` flags have been removed as well. Some files were not as easily converted. Most were simple keyword changes though there are a couple instances where the file structure is redone to accommodate ES6 exports.
Configuration menu - View commit details
-
Copy full SHA for 073d060 - Browse repository at this point
Copy the full SHA 073d060View commit details
Commits on Dec 17, 2019
-
Configuration menu - View commit details
-
Copy full SHA for 11a3bdd - Browse repository at this point
Copy the full SHA 11a3bddView commit details -
Configuration menu - View commit details
-
Copy full SHA for c5b8ffc - Browse repository at this point
Copy the full SHA c5b8ffcView commit details -
Configuration menu - View commit details
-
Copy full SHA for 3cdddf8 - Browse repository at this point
Copy the full SHA 3cdddf8View commit details -
Configuration menu - View commit details
-
Copy full SHA for c34568e - Browse repository at this point
Copy the full SHA c34568eView commit details -
Configuration menu - View commit details
-
Copy full SHA for b69865b - Browse repository at this point
Copy the full SHA b69865bView commit details -
Configuration menu - View commit details
-
Copy full SHA for c5d0eb1 - Browse repository at this point
Copy the full SHA c5d0eb1View commit details -
Configuration menu - View commit details
-
Copy full SHA for f8b8d9a - Browse repository at this point
Copy the full SHA f8b8d9aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 1b4e79f - Browse repository at this point
Copy the full SHA 1b4e79fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 1b1fed6 - Browse repository at this point
Copy the full SHA 1b1fed6View commit details -
Configuration menu - View commit details
-
Copy full SHA for b0e8271 - Browse repository at this point
Copy the full SHA b0e8271View commit details -
Configuration menu - View commit details
-
Copy full SHA for a59befc - Browse repository at this point
Copy the full SHA a59befcView commit details -
Configuration menu - View commit details
-
Copy full SHA for 9e28251 - Browse repository at this point
Copy the full SHA 9e28251View commit details -
Move browser stuff back to dist
Dist is where you Distribute things.
Configuration menu - View commit details
-
Copy full SHA for 735281f - Browse repository at this point
Copy the full SHA 735281fView commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.