i18next-express-middleware
Advanced tools
Comparing version 1.9.1 to 2.0.0
@@ -0,1 +1,5 @@ | ||
### 2.0.0 | ||
- typescript: Update typings to export I18NextRequest instead of extending global express Request [211](https://github.com/i18next/i18next-express-middleware/pull/211) | ||
### 1.9.1 | ||
@@ -2,0 +6,0 @@ |
import * as express from 'express'; | ||
import * as i18next from 'i18next'; | ||
declare global { | ||
namespace Express { | ||
interface Request { | ||
language: string; | ||
languages: string[]; | ||
i18n:i18next.i18n; | ||
t:i18next.TFunction | ||
} | ||
} | ||
} | ||
@@ -20,2 +10,9 @@ declare module 'i18next-express-middleware' { | ||
type I18NextRequest = express.Request & { | ||
language: string; | ||
languages: string[]; | ||
i18n:i18next.i18n; | ||
t:i18next.TFunction; | ||
} | ||
interface HandleOptions { | ||
@@ -22,0 +19,0 @@ ignoreRoutes?: string[] | IgnoreRoutesFunction; |
{ | ||
"name": "i18next-express-middleware", | ||
"version": "1.9.1", | ||
"version": "2.0.0", | ||
"description": "express middleware for i18next", | ||
@@ -5,0 +5,0 @@ "main": "./lib/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
33184
537