Commit Graph
16 Commits
Author SHA1 Message Date
Seiyaandfisker 1bf47c1e95 Format TS expressions when any script tag has lang="ts" (#14587)
Co-authored-by: fisker <lionkay@gmail.com>
2023-03-27 10:47:54 +08:00
Sosuke Suzuki a4cba80dc0 Allow formatting for Vue template expression written in TypeScript (#12584)
* Support TS expression in vue SFC

* Add changelog

* Add `__ts_expression`

* Add `__vue_ts_expression`

* Add tests

* Do not use `ast.walk`

* Address review

* Add `__vue_ts_event_binding`

* Fix
2022-04-17 13:12:19 +09:00
Sosuke Suzuki ff78a94424 Reduce bundle size of parser-html.js (#12176) 2022-01-28 10:07:37 +08:00
翠 / greenandfisker Cheung dd3e1a49e0 Improved performance with large HTML files (#11696)
* Simplify Object.assign

* Remove copying ast inside addIsSpaceSensitive

* Remove copying ast inside extractWhitespaces

* Remove copying ast inside removeIgnorableFirstLf

* Remove copying ast inside mergeIeConditonalStartEndCommentIntoElementOpeningTag

* Remove copying ast inside mergeNodeIntoText

* Remove copying ast inside mergeSimpleElementIntoText

* Remove copying ast inside extractInterpolation

* Remove copying ast inside _parse

* Remove copying ast inside preprocess

* Fix lint

* Refactor index/next/prev recalculation with loop

* Remove redundant condition

Co-authored-by: fisker Cheung <lionkay@gmail.com>

* Remove index/siblings from properties

* Define and use replaceChild method

* Change prev/next into getter

* Make parent non writable

* setNonEnumerableProperties to setNonEnumerableProperty

* Set parent with constructor

* Make parent a normal property

* Use child.prev/next

* Remove parent parameter from constructor

Co-authored-by: fisker Cheung <lionkay@gmail.com>
2022-01-11 10:06:46 -03:00
dependabot[bot] 56577a466b Build(deps-dev): Bump cspell from 5.14.0 to 5.15.1 (#12063) 2022-01-09 08:15:06 -03:00
dependabot[bot]andfisker Cheung ea701359b7 Build(deps-dev): Bump eslint-plugin-regexp from 0.13.2 to 1.0.0 (#11351)
* Build(deps-dev): Bump eslint-plugin-regexp from 0.13.2 to 1.0.0

Bumps [eslint-plugin-regexp](https://github.com/ota-meshi/eslint-plugin-regexp) from 0.13.2 to 1.0.0.
- [Release notes](https://github.com/ota-meshi/eslint-plugin-regexp/releases)
- [Commits](https://github.com/ota-meshi/eslint-plugin-regexp/compare/v0.13.2...v1.0.0)

---
updated-dependencies:
- dependency-name: eslint-plugin-regexp
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update options for `regexp/no-useless-flag` rule

* Remove useless flag

* Fix style

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: fisker Cheung <lionkay@gmail.com>
2021-08-24 10:31:24 +09:00
fisker Cheung 894f841fbd Style: Enforce extensions (#11227) 2021-07-21 09:10:34 +08:00
ryoha c69d0d88b0 change map to walk in html/print-preprocess (#11108) 2021-07-01 19:46:24 +09:00
fisker Cheung 9b7ba8a42c Style: Use dotAll regexp (#10864) 2021-05-18 02:44:21 +08:00
fisker CheungandGeorgii Dolzhykov 2e1021ca79 Reduce use of Array#reduce() (#10863)
Co-authored-by: Georgii Dolzhykov <thorn.mailbox@gmail.com>
2021-05-16 12:43:13 +08:00
Georgii Dolzhykov 3d8dc612b5 Bump Prettier dependency to 2.3.0 2021-05-10 00:07:47 +03:00
fisker Cheung 230428f34b Add consistent-negative-index-access rule (#10569) 2021-03-20 14:06:12 +02:00
fisker Cheung ce26805e84 Enable unicorn/prefer-spread (#10129) 2021-01-26 09:46:14 +08:00
fisker Cheung 181a325c1c Enable unicorn/explicit-length-check (#9975) 2021-01-04 10:11:57 +08:00
fisker Cheung 0fd2a28cff Enable arrow-body-style rule (#9918) 2020-12-17 14:31:51 +08:00
fisker Cheung 7d608bafc7 Rename preprocess and postprocess file (#9651) 2020-11-14 14:55:07 +08:00