Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeScript Rollout Tier 3 #302

Closed
Tracked by #151
kikuomax opened this issue Dec 25, 2024 · 0 comments · Fixed by #326
Closed
Tracked by #151

TypeScript Rollout Tier 3 #302

kikuomax opened this issue Dec 25, 2024 · 0 comments · Fixed by #326
Assignees
Labels
enhancement New feature or request

Comments

@kikuomax
Copy link
Collaborator

kikuomax commented Dec 25, 2024

Migration of utils/config.ts.

@kikuomax kikuomax mentioned this issue Dec 25, 2024
37 tasks
@kikuomax kikuomax added the enhancement New feature or request label Dec 25, 2024
@kikuomax kikuomax changed the title Tier 3 - components without dependencies TypeScript Rollout Tier 3 Dec 25, 2024
@kikuomax kikuomax self-assigned this Dec 25, 2024
@kikuomax kikuomax moved this to 🔖 Ready in Buefy Vue3 Project Board Dec 30, 2024
@kikuomax kikuomax moved this from 🔖 Ready to 👀 In review in Buefy Vue3 Project Board Dec 31, 2024
kikuomax added a commit that referenced this issue Dec 31, 2024
* chore(lib): rename utils/config.js → .ts

Renames `utils/config.js` to `utils/config.ts` without correcting
TypeScript errors. This is to track changes before and after rewriting
it in TypeScript.

* feat(lib): rewrite utils/config in TS

Actually rewrites `utils/config.ts` in TypeScript:
Introduces new types:
- `BuefyConfig`: type for the entire Buefy config. I will refine the
  type of `BuefyConfig.customIconPacks` while rewriting
  `utils/icons.ts`
- `BuefyConfigOptions`: `BuefyConfig` with all the properties optional
- `ModalCancellableOption`
- `ModalScrollOption`
- `FieldLabelPosition`
- `NoticePosition`: possible values are defined in `NOTICE_POSITIONS`

Introduces a new type `VueClassAttribute` that represents the type for
values that can be bound to "class" attributes of DOM elements, since
Vue does not provide it. There might be better place for this type, but
defines it in `utils/config.ts` for now.

`index.ts` uses `BuefyConfigOptions` to represent the type of `options`
parameter of the `install` plugin method. It also exports types exported
from 'utils/config.ts'. Adds the type parameter to the `merge` call.

* test(lib): rewrite utils/config.spec in TS

- Rewrites `utils/config.spec.js` in TypeScript →
  `utils/config.spec.ts`. Imports necessary functions from `vitest`.
@kikuomax kikuomax moved this from 👀 In review to Pending Release🔦 in Buefy Vue3 Project Board Dec 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: Pending Release🔦
Development

Successfully merging a pull request may close this issue.

1 participant