-
Notifications
You must be signed in to change notification settings - Fork 397
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: add flow types and fix package exports
Closes #250
- Loading branch information
1 parent
567e730
commit b93d0ee
Showing
19 changed files
with
87 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1 @@ | ||
// Replace in Babel 7.x (https://github.com/babel/babel/issues/2877): | ||
// export * from "./src/api" | ||
module.exports = require("./src/api") | ||
export * from "./src/api" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1 @@ | ||
// Replace in Babel 7.x (https://github.com/babel/babel/issues/2877): | ||
// export * from "./src/lingui" | ||
module.exports = require("./src/lingui") | ||
export * from "./src/lingui" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1 @@ | ||
// Replace in Babel 7.x (https://github.com/babel/babel/issues/2877): | ||
// export * from "./src" | ||
module.exports = require("./src") | ||
export * from "./src" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1 @@ | ||
// Replace in Babel 7.x (https://github.com/babel/babel/issues/2877): | ||
// export * from "./src" | ||
module.exports = require("./src") | ||
export * from "./src" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,6 +26,7 @@ | |
"README.md", | ||
"index.js", | ||
"dev.js", | ||
"*.js.flow", | ||
"cjs/" | ||
], | ||
"dependencies": { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1 @@ | ||
// Replace in Babel 7.x (https://github.com/babel/babel/issues/2877): | ||
// export { default } from "./src" | ||
module.exports = require("./src") | ||
export { default } from "./src" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1 @@ | ||
// Replace in Babel 7.x (https://github.com/babel/babel/issues/2877): | ||
// export * from "./src" | ||
module.exports = require("./src") | ||
export * from "./src" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
/* @flow */ | ||
// @flow | ||
import * as React from "react" | ||
import { mount, shallow } from "enzyme" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,26 @@ | ||
// @flow | ||
import { date, number } from "@lingui/core" | ||
|
||
import createFormat from "./createFormat" | ||
import I18nProvider from "./I18nProvider" | ||
import Trans from "./Trans" | ||
import { Plural, Select, SelectOrdinal } from "./Select" | ||
|
||
import createFormat from "./createFormat" | ||
import withI18n from "./withI18n" | ||
import type { withI18nProps } from "./withI18n" | ||
export { withI18n } | ||
export type { withI18nProps } | ||
|
||
export { default as I18nProvider } from "./I18nProvider" | ||
export { default as Trans } from "./Trans" | ||
export { Plural, Select, SelectOrdinal } from "./Select" | ||
const DateFormat = withI18n()(createFormat(date)) | ||
const NumberFormat = withI18n()(createFormat(number)) | ||
|
||
export const DateFormat = withI18n()(createFormat(date)) | ||
export const NumberFormat = withI18n()(createFormat(number)) | ||
const i18nMark = (id: string) => id | ||
|
||
export const i18nMark = (id: string) => id | ||
export { | ||
i18nMark, | ||
withI18n, | ||
I18nProvider, | ||
Trans, | ||
Plural, | ||
Select, | ||
SelectOrdinal, | ||
DateFormat, | ||
NumberFormat | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,20 @@ | ||
{ | ||
"bundleSizes": { | ||
"@lingui/core.development.js (NODE_DEV)": { | ||
"size": 13974, | ||
"gzip": 3692 | ||
"size": 13895, | ||
"gzip": 3636 | ||
}, | ||
"@lingui/core.production.min.js (NODE_PROD)": { | ||
"size": 5741, | ||
"gzip": 1892 | ||
"size": 5800, | ||
"gzip": 1902 | ||
}, | ||
"@lingui/react.development.js (NODE_DEV)": { | ||
"size": 18214, | ||
"gzip": 5063 | ||
"size": 18086, | ||
"gzip": 4999 | ||
}, | ||
"@lingui/react.production.min.js (NODE_PROD)": { | ||
"size": 8598, | ||
"gzip": 3084 | ||
"size": 8664, | ||
"gzip": 3099 | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters