For https://github.com/vector-im/riot-web/issues/3304
This generates something similar to what the rageshake server does, just in an easy package for people to use. tar-js was chosen over zip or anything else because it's small, simple, and stable.
Note: this doesn't work in Chrome, but firefox seems to be okay with it. Chrome appears to be blocking the download for some reason - the very first download was fine, but none afterwards
This is required for jsdom to do the right thing.
We also have to bump the jsdom version, but to do that we need an alternative test environment because Jest has it pinned lower.
There's a bunch of generated files that webpack relies on to work, and Karma works off webpack. To make both happy we've added
a new `build:genfiles` script which takes care of this for us. We also have to install and build our other layers to get the
same effect (like generating the react-sdk's component index, while we still have one).
This commit also fixes all the imports in the tests because they were just wrong. They should have been caught in the ES6ification
earlier, but were missed.
We previously ignored this whole directory, and it's a bit of wishful thinking that we'll have these delinted as a result.
Switching to Jest should fix most of the problems anyways, so we can enable the linter when we get there.
We have to convert *something* to TypeScript so it doesn't complain that there's nothing to compile, so this converts the easiest utility library.
Many of the scripts are copied from the react-sdk.
Run `yarn install` in the js-sdkc and react-sdk installs. We were
avoiding this before due to using babel dependencies from riot-web
ro build js-sdk, which worked as long as the installed babel versions
and plugins were identical. js-sdk has now been upgraded to babel 7
and so that no longer worked.
This will probably cause react-sdk & js-sdk to be built an
unnecessary number of times.
This covers the "recents" section and rough design exclusively. It is known that the Field does nothing and that there's a bunch of missing functionality - this is to be iterated upon in future PRs. Labs flag is to aide development and should be removed in a very near future PR.
Also, this is focusing on DMs and not user lists in general because I misinterpreted the scope. I'll fix this in a future PR and instead make this the best DM invite dialog it can be.
Closes https://github.com/vector-im/riot-web/issues/11197
This moves the babel and postcss configs into the webpack config for ease of maintenance (and because we need variations of them). The typescript config is left outside the webpack config for IDEs to pick it up.