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

Bug(transloco-utils): TranslocoGlobalConfig interface is missing "sort" property #825

Open
1 task done
xDivisionByZerox opened this issue Jan 9, 2025 · 0 comments
Open
1 task done

Comments

@xDivisionByZerox
Copy link
Contributor

Is there an existing issue for this?

  • I have searched the existing issues

Which Transloco package(s) are the source of the bug?

Don't know / other

Is this a regression?

No

Current behavior

The TranslocoGlobalConfig interface is missing the "keysManager.sort" property. As a result, the following TypeScript configuration file does not work without additional modifications, because TypeScript reports that the "keysManager.sort" property does not exist on the TranslocoGlobalConfig interface.

import type { TranslocoGlobalConfig } from "@jsverse/transloco-utils";

const config: TranslocoGlobalConfig = {
  keysManager: {
    sort: true,
  }
}

export default config;

If you remove the types and run a TKM command, it functions as expected (sorting the keys). The issue lies solely with the interface.

Expected behavior

I can define the "keysManager.sort" property on the configuration object while keeping the type without additional modifications to the type itself.

Please provide a link to a minimal reproduction of the bug, if you won't provide a link the issue won't be handled.

https://stackblitz.com/edit/stackblitz-starters-4pegy8i9?file=transloco.config.ts&view=editor

Transloco Config

No response

Please provide the environment you discovered this bug in

Transloco: 7.5.0
Angular: 18.2.12
Node: 20.18.1
Package Manager: [email protected]
OS: Ubuntu 22.04.5 LTS

Browser

No response

Additional context

No response

I would like to make a pull request for this bug

Yes 🚀

@xDivisionByZerox xDivisionByZerox changed the title Bug(scope): TranslocoGlobalConfig interface is missing "sort" property Bug(transloco-utils): TranslocoGlobalConfig interface is missing "sort" property Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant