iamkun / iamkun/dayjs

[TS] Duplicate identifier 'locale'

Open
#1,739 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
48.7k
Forks
2.8k
PR merge metrics
No merged PRs in 30d

Description

Error: ../../../node_modules/dayjs/locale/index.d.ts:10:12 - error TS2300: Duplicate identifier 'locale'.

10 export = locale

node_modules/dayjs/locale/index.d.ts:10:12
10 export = locale

'locale' was also declared here.

Information

  • Day.js Version [1.10.7]
  • OS: [Windows 10]
  • Platform [Angular 12.2.14]

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the TypeScript error in node_modules/dayjs/locale/index.d.ts within the reported Angular 12.2.14 setup. Trace why locale is declared twice, then verify that the duplicate-identifier error no longer occurs in the affected TypeScript build.

Written by the indexing model from the issue text.

Assessment

Tech stack
angular, typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.