Commit Graph

71 Commits (942846c46b68dec4aca334051a613b62a78bcb1c)

Author SHA1 Message Date
Chocobozzz 338633ce72
Remove barrels
They can prevent tree shaking
2024-03-05 10:52:32 +01:00
Chocobozzz 3a4992633e
Migrate server to ESM
Sorry for the very big commit that may lead to git log issues and merge
conflicts, but it's a major step forward:

 * Server can be faster at startup because imports() are async and we can
   easily lazy import big modules
 * Angular doesn't seem to support ES import (with .js extension), so we
   had to correctly organize peertube into a monorepo:
    * Use yarn workspace feature
    * Use typescript reference projects for dependencies
    * Shared projects have been moved into "packages", each one is now a
      node module (with a dedicated package.json/tsconfig.json)
    * server/tools have been moved into apps/ and is now a dedicated app
      bundled and published on NPM so users don't have to build peertube
      cli tools manually
    * server/tests have been moved into packages/ so we don't compile
      them every time we want to run the server
 * Use isolatedModule option:
   * Had to move from const enum to const
     (https://www.typescriptlang.org/docs/handbook/enums.html#objects-vs-enums)
   * Had to explictely specify "type" imports when used in decorators
 * Prefer tsx (that uses esbuild under the hood) instead of ts-node to
   load typescript files (tests with mocha or scripts):
     * To reduce test complexity as esbuild doesn't support decorator
       metadata, we only test server files that do not import server
       models
     * We still build tests files into js files for a faster CI
 * Remove unmaintained peertube CLI import script
 * Removed some barrels to speed up execution (less imports)
2023-08-11 15:02:33 +02:00
Chocobozzz a1bd2b77d9
Remove webtorrent support from client 2023-07-10 16:08:28 +02:00
Chocobozzz 866c5f667d
Simplify ICU in components 2023-06-29 09:49:06 +02:00
Chocobozzz 5490930428
Remove suppressImplicitAnyIndexErrors
It's deprecated by TS
2023-05-24 16:56:05 +02:00
Chocobozzz 838950fd6b
Upgrade to latest angular version 2023-02-16 14:21:11 +01:00
Chocobozzz f228e9f064
More precise date for jobs 2022-08-10 10:26:20 +02:00
Chocobozzz eaa529528c
Support ICU in TS components 2022-06-08 13:40:40 +02:00
Chocobozzz f304a1580b
Fix build 2021-12-17 13:58:07 +01:00
lutangar 8b03e2ce1a feat(types): create peertube-types package
Create dedicated Typescript "types" configuration file for each "projects".
Create a types folder which includes every useful ts definition:
- client
- server
- shared
Add tooling to create a proper package, extract dependencies, etc...
Add CI Github task.

refactor(types): publish types package in release script
2021-12-16 10:08:43 +01:00
Chocobozzz 9df52d660f
Migrate client to eslint 2021-08-18 08:35:06 +02:00
Chocobozzz 1d4591fd9c
Remove solution style ts config 2021-08-17 14:06:56 +02:00
Chocobozzz 583eb04b54 Upgrade to angular 10 2020-08-07 08:28:14 +02:00
Rigel Kent 4504f09f6e deal with refresh token in embed 2020-08-06 15:08:58 +02:00
Chocobozzz 27da4884ed
Use tslib in client 2020-06-09 14:52:55 +02:00
Chocobozzz 512decf37e
Fix videojs 2020-04-21 11:02:28 +02:00
Chocobozzz 7e37e11111
Fix videojs typings 2020-04-17 14:12:43 +02:00
Chocobozzz 9cdeb80650
Fix videojs subtitles 2020-04-08 09:36:51 +02:00
Chocobozzz be27ef3b46 Strict templates enabled 2020-02-10 16:39:28 +01:00
Chocobozzz f5fcd9f725
Correctly type videojs player 2020-01-29 11:48:15 +01:00
Chocobozzz 16b5525950
Update Angular -> 8.2.0 2019-08-01 11:38:47 +02:00
Chocobozzz f36da21e40
Update angular 2019-07-25 11:00:43 +02:00
Chocobozzz 93cae47925 Add client hooks 2019-07-24 10:58:16 +02:00
Chocobozzz c47106315a
tslint update 2019-04-02 18:30:26 +02:00
Chocobozzz 830b4faff1 Add/update/delete/list my playlists 2019-03-18 11:17:59 +01:00
Chocobozzz 4348a27d25 Add lazy loading in player 2019-02-11 09:13:02 +01:00
BO41 951ef8294e add noImplicitThis flag (#1324) 2018-10-24 21:50:18 +02:00
BO41 244b4ae397 NoImplicitAny flag true (#1157)
this enables the `noImplicitAny` flag in the Typescript compiler

> When the noImplicitAny flag is true and the TypeScript compiler cannot infer the type, it still generates the JavaScript files, but it also reports an error. Many seasoned developers prefer this stricter setting because type checking catches more unintentional errors at compile time.

closes: #1131
replaces #1137
2018-10-18 09:08:59 +02:00
BO41 5b3f86dd80 add alwaysStrict flag to client/tsconfig.json (#1280) 2018-10-15 14:35:18 +02:00
Chocobozzz 07524e229f
Enable more angular options 2018-09-28 10:36:46 +02:00
Chocobozzz f2e05ffea7
Try to fix embed webpack build 2018-09-03 11:26:19 +02:00
Chocobozzz 0b18f4aa80 Add advanced search in client 2018-07-24 14:04:05 +02:00
William Lahti 3ea9a1c311 Replace angular-cli patch with something less risky (#742)
* Replace angular-cli patch with something less risky

* path.join() is needed, provide a naive implementation

* technically, webpack provided a polyfill for Buffer, we should too

* process polyfill matches webpack; peertube depends on nextTick

* polyfill for path to match webpack

* http/https polyfills as per webpack
2018-06-28 15:53:04 +02:00
Chocobozzz 6cca7360eb
Reduce bundle sizes 2018-06-07 16:50:33 +02:00
Chocobozzz 920d2d2b4c
Add libs to tsconfig 2018-05-07 10:37:43 +02:00
Chocobozzz 4cb6d45788
Add ability to delete comments 2018-01-04 11:19:16 +01:00
Chocobozzz 63c4db6d71
Move to angular cli 2017-12-12 10:58:16 +01:00
Chocobozzz 8635a2c70c Update client modules 2017-06-11 12:28:22 +02:00
Chocobozzz a17bc2c34e Client: use tslib instead of ts-helpers 2017-02-10 10:28:11 +01:00
Chocobozzz e31f6ad637 Client: use videojs as player 2016-11-08 20:49:43 +01:00
Chocobozzz ad22074a78 Client: fix prod build process 2016-09-19 22:27:17 +02:00
Chocobozzz ab32b0fc80 Dirty update to Angular RC6 2016-09-06 22:40:57 +02:00
Chocobozzz 039cdfc528 Client: do not rewrite tsconfig at each change of a file 2016-08-23 17:45:02 +02:00
Chocobozzz bf68dd752d Client: fix error display for component 2016-08-23 17:42:56 +02:00
Chocobozzz de59c48f5f Client: centralize http res extraction in a service 2016-08-23 16:54:21 +02:00
Chocobozzz 9e8aa10d94 Client: change url validation for friend add 2016-08-23 15:49:16 +02:00
Chocobozzz e105c19c8e Client: support the new make friends method 2016-08-21 10:41:21 +02:00
Chocobozzz 7eef95353f Client: reset pagination when we search something 2016-08-15 19:05:52 +02:00
Chocobozzz e2f555cab7 Client: add friends page 2016-08-12 18:22:58 +02:00
Chocobozzz 602eb142be Client: make an admin menu and a classic menu component 2016-08-12 16:53:32 +02:00