hexojs / hexo-util

Utilities for Hexo.
MIT License
93 stars 59 forks source link

refactor: migrate from `js` to `ts` #284

Closed yoshinorin closed 2 years ago

coveralls commented 2 years ago

Coverage Status

Coverage increased (+4.3%) to 95.54% when pulling e28f5d0babd8ae8aaeeb465086c242aff90c48c7 on refactor/migrate-to-ts into 282e1e5a5def94877efbefa0cb1a16417bcba921 on master.

SukkaW commented 2 years ago

@yoshinorin Actually we have a better option. Currently, @liby is working on porting hexo-util to Rust binding, to have better performance and speed (and first-party typescript typing supports). See https://github.com/liby/hexo-util-rs.

liby commented 2 years ago

Hi, @yoshinorin If you're interested, you can take a look under the hexo-util-rs/tree/main/common folder.

This folder contains the following:

  1. Waiting to be RIIR
  2. Has been tried and is not suitable for RIIR

Welcome to your PR.

yoshinorin commented 2 years ago

Sounds interesting! I will try learning Rust :)

liby commented 2 years ago

I will try learning Rust :)

There are actually some other jobs that can be done, For example:

  1. Migrate the .js files in the common folder to .ts, if you think it's necessary.
  2. Improve the test.
  3. Improve type definition.
  4. ...
stevenjoezhang commented 2 years ago

We can merge this pull request first, and then start migrating to rust.

yoshinorin commented 2 years ago

@stevenjoezhang Thank you ❤️ Let's release v3.0.0 🚀