Use ESBuild for frontend build.

Replacing webpack by ESBuild for client code compilation (as in the
official quickstart plugin).

So we can remove deprecated webpack dependencies.

Note: webpack is still used for ConverseJS build.
This may be removed soon.

Related to issue #122.
This commit is contained in:
John Livingston
2022-12-07 18:36:16 +01:00
parent 901d1e96ab
commit c178213e19
14 changed files with 677 additions and 7760 deletions

View File

@ -205,3 +205,5 @@ function launchTests (): void {
}
launchTests()
export {}

View File

@ -13,6 +13,9 @@
"noImplicitReturns": true,
"strictBindCallApply": true, // should already be true because of strict:true
"noUnusedLocals": true,
"allowSyntheticDefaultImports": true, // Seems necessary for peertube types to work
"isolatedModules": true, // Needed by esbuild https://esbuild.github.io/content-types/#isolated-modules
"esModuleInterop": true, // Needed by esbuild https://esbuild.github.io/content-types/#es-module-interop
"outDir": "../dist/client",
"paths": {
"shared/*": ["../shared/*"]

View File

@ -50,7 +50,9 @@ function displayButton ({
buttonContainer.append(button)
}
export type {
displayButtonOptions
}
export {
displayButtonOptions,
displayButton
}

View File

@ -103,6 +103,8 @@ export {
closeSVG,
openChatSVG,
openBlankChatSVG,
shareChatUrlSVG,
shareChatUrlSVG
}
export type {
SVGButton
}

View File

@ -66,8 +66,10 @@ function getIframeUri (
return iframeUriStr
}
export type {
UriOptions
}
export {
UriOptions,
getBaseRoute,
getIframeUri
}