diff --git a/package.json b/package.json index d94b439a..39caa6a7 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,8 @@ "name": "@prestashop-core/ui-testing", "version": "0.0.2", "description": "", - "files": ["/dist"], + "main": "dist/index.js", + "types": "dist/index.d.ts", "scripts": { "test": "echo \"Error: no test specified\" && exit 1", "// ESLint": "To run ESLint commands", diff --git a/src/index.ts b/src/index.ts new file mode 100644 index 00000000..91c171d8 --- /dev/null +++ b/src/index.ts @@ -0,0 +1,15 @@ +// Export data +export type {PageWaitForSelectorOptionsState, WaitForNavigationWaitUntil} from '@data/types/playwright'; + +// Export interfaces +export type {DashboardPageInterface} from '@interfaces/BO/dashboard'; +export type {LoginPageInterface} from '@interfaces/BO/login'; + +// Export Pages +export * as CommonPage from '@pages/commonPage'; +export * as BOBasePage from '@pages/BO/BOBasePage'; +export * as loginPage from '@pages/BO/login'; +export * as dashboardPage from '@pages/BO/dashboard'; + +// Export utils +export * as testContext from '@utils/testContext'; \ No newline at end of file diff --git a/src/types/globals.d.ts b/src/types/globals.d.ts index 1213872b..6fe60c55 100644 --- a/src/types/globals.d.ts +++ b/src/types/globals.d.ts @@ -1,6 +1,6 @@ /* eslint-disable vars-on-top, no-var */ -type GlobalInstall = { + type GlobalInstall = { URL: string ENABLE_SSL: boolean LANGUAGE: string diff --git a/tsconfig.json b/tsconfig.json index f4e72156..bc48ef99 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -20,6 +20,7 @@ "esnext" ], "baseUrl": "./", + "rootDir": "src", "outDir": "./dist", "paths": { "@interfaces/*": [ @@ -47,7 +48,7 @@ ], }, "include": [ - "src/**/*" + "src/index.ts" ], "exclude": [ "node_modules"