Jack Franklin
e839c0cf22
Enable long import wrapping for JS imports
...
DISABLE_THIRD_PARTY_CHECK=big clang format run against all files in
front_end and test/
Bug: 1319340
Change-Id: I1fff63cb07544ccd0e3059fc901f9a48ff4af13b
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3598879
Reviewed-by: Alex Rudenko <alexrudenko@chromium.org >
Commit-Queue: Jack Franklin <jacktfranklin@chromium.org >
Reviewed-by: Wolfgang Beyer <wolfi@chromium.org >
2022-05-03 10:22:12 +00:00
Tim van der Lippe
b67a3f0877
Fix GN dependencies
...
The formatter model creates a worker that references the formatter_worker
entrypoint. However, it wasn't depending on it as such. Therefore,
to ensure deterministic building, we have to add the entrypoint as
dependency to the model. That required another tidy up, as there was
a type defined in the model that was used in the entrypoint. We can
move that type to the entrypoint to circumvent the issue.
Additionally, fix the dependency on Images and themeColors.css to make
them available as expected when running unit tests.
R=jacktfranklin@chromium.org
Fixed: 1284865
Change-Id: I9d1eb6877629ccb5dd5ed105a10acf6291275610
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3369364
Commit-Queue: Tim Van der Lippe <tvanderlippe@chromium.org >
Auto-Submit: Tim Van der Lippe <tvanderlippe@chromium.org >
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org >
Commit-Queue: Jack Franklin <jacktfranklin@chromium.org >
2022-01-06 12:26:09 +00:00
Jan Scheffler
ad7a2ddd4c
[Underscore Migration] Migrate models/formatter
...
This patch is part of the underscore migration that adds the private
keyword to all properties that start with an underscore and removes the
underscore.
Bug:chromium:1207342
Change-Id: I386ec317f4a944135feba6d40b0d9849c7d4ccdc
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3077893
Commit-Queue: Jan Scheffler <janscheffler@chromium.org >
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org >
Auto-Submit: Jan Scheffler <janscheffler@chromium.org >
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org >
2021-08-06 16:04:06 +00:00
Tim van der Lippe
fb38e368e9
Add tests for ScriptFormatter
...
With these tests, we achieve 100% test coverage (barring the 2
missing branches from the initialization of the setting, which
we can't test in a unit test environment).
I also renamed the fields in the object that is returned, as they
make sense and almost all usages were renaming them anyways.
R=szuend@chromium.org
Bug: 1009443
Change-Id: I3ac6cdf3cca99baf312d0d4e4036e7f95e9ef06d
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3056375
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org >
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org >
Reviewed-by: Simon Zünd <szuend@chromium.org >
2021-07-27 16:33:09 +00:00
Tim van der Lippe
6df5ce7fbd
Return promise instead of using callbacks
...
This should improve the testability of these functions. Hopefully,
a follow-up CL can introduce some tests for this API.
R=szuend@chromium.org
Bug: none
Change-Id: If0d1884e5abed05520cbc9cfe42c99052550d9ba
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3055240
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org >
Commit-Queue: Simon Zünd <szuend@chromium.org >
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org >
Reviewed-by: Simon Zünd <szuend@chromium.org >
2021-07-27 11:29:59 +00:00
Tim van der Lippe
ea2fe19c2d
Use functions instead of classes for formatter
...
Both of these classes were performing side-effect work in their
constructor and eventually calling the callback. Instead, these
should become proper functions.
In a follow-up CL, I will also remove the callback and refactor
to return proper promises instead.
R=szuend@chromium.org
Bug: none
Change-Id: I91d91f04c5ade75ee7e124719f1285a8a09a44be
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3053748
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org >
Reviewed-by: Simon Zünd <szuend@chromium.org >
2021-07-27 10:04:09 +00:00
Tim van der Lippe
3c3cd80fc6
Remove FormatterInterface
...
This class was a remnant of the code structure during the Closure
Compiler era. In ES modules, we no longer need a special class
and instead can explicitly export the relevant functions and
remove the interim class.
R=szuend@chromium.org
Bug: none
Change-Id: Ib6a2bcaef9a1dad462f02a3411b9bef1ee989a34
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3053747
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org >
Reviewed-by: Simon Zünd <szuend@chromium.org >
2021-07-27 09:53:09 +00:00
Tim van der Lippe
c2cbf32af8
Remove no-unused-vars suppressions
...
We don't use this rule any longer. Therefore, any supression of
the rule is considered a no-op. (We use the typescript-eslint
version instead).
R=jacktfranklin@chromium.org
Bug: none
Change-Id: I13595fffc980db423ee8ad5d133fd187d0dbdbbb
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3053746
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org >
Commit-Queue: Paul Lewis <aerotwist@chromium.org >
Reviewed-by: Paul Lewis <aerotwist@chromium.org >
2021-07-27 09:48:39 +00:00
Jack Franklin
a75ae7cbb3
Enforce import type when importing TS types.
...
Bug: none
Change-Id: I02ef1182143b7fe091ce92d59f04ac2188903e0d
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2886925
Commit-Queue: Jack Franklin <jacktfranklin@chromium.org >
Auto-Submit: Jack Franklin <jacktfranklin@chromium.org >
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org >
Reviewed-by: Mathias Bynens <mathias@chromium.org >
2021-05-11 14:00:22 +00:00
Tim van der Lippe
a9ae810860
Move formatter to models/formatter
...
R=aerotwist@chromium.org
Bug: 1187573
Change-Id: Idc2b0f88665e276f692515afe667517a4e5ed245
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2831975
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org >
Reviewed-by: Paul Lewis <aerotwist@chromium.org >
2021-04-19 14:18:33 +00:00