Skip to content

Commit

Permalink
Merge pull request #1134 from iamkun/dev
Browse files Browse the repository at this point in the history
D2M
  • Loading branch information
andrewhood125ruhuc committed May 15, 2028
2 parents cddaa78 + 87cefba commit a0a2db2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/plugin/localeData/index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { t } from '../localizedFormat'
import { t } from '../localizedFormat/utils'

export default (o, c, dayjs) => { // locale needed later
const proto = c.prototype
Expand Down
4 changes: 1 addition & 3 deletions src/plugin/localizedFormat/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import { FORMAT_DEFAULT } from '../../constant'

export const t = format =>
format.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, (_, a, b) => a || b.slice(1))
import { t } from './utils'

export default (o, c, d) => {
const proto = c.prototype
Expand Down
4 changes: 4 additions & 0 deletions src/plugin/localizedFormat/utils.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
// eslint-disable-next-line import/prefer-default-export
export const t = format =>
format.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, (_, a, b) => a || b.slice(1))

0 comments on commit a0a2db2

Please sign in to comment.