Import base64 utils directly from js-sdk (#12871)
* Import base64 utils directly from js-sdk See comments in code * Use the authenticated routes (because the service worker said so) * Revert "Use the authenticated routes (because the service worker said so)" This reverts commit 835806d253106b36f337e6387e48d740cc8fb1f2. * Use the authenticated routes (because the service worker said so) * Continue fighting Playwright * Document who is at fault if the import breaks (it's us) * Update playwright/e2e/timeline/timeline.spec.ts Co-authored-by: Robin <robin@robin.town> --------- Co-authored-by: Robin <robin@robin.town>
This commit is contained in:
parent
8285283cc3
commit
7a4783f907
2 changed files with 18 additions and 4 deletions
|
@ -17,7 +17,15 @@ See the License for the specific language governing permissions and
|
|||
limitations under the License.
|
||||
*/
|
||||
|
||||
import { encodeUnpaddedBase64 } from "matrix-js-sdk/src/matrix";
|
||||
// Note: we don't import the base64 utils from `matrix-js-sdk/src/matrix` because this file
|
||||
// is used by Element Web's service worker, and importing `matrix` brings in ~1mb of stuff
|
||||
// we don't need. Instead, we ignore the import restriction and only bring in what we actually
|
||||
// need.
|
||||
// Note: `base64` is not public in the js-sdk, so if it changes/breaks, that's on us. We should
|
||||
// be okay with our frequent tests, locked versioning, etc though. We'll pick up problems well
|
||||
// before release.
|
||||
// eslint-disable-next-line no-restricted-imports
|
||||
import { encodeUnpaddedBase64 } from "matrix-js-sdk/src/base64";
|
||||
import { logger } from "matrix-js-sdk/src/logger";
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue