diff --git a/examples/symbolPlugin/package.json b/examples/symbolPlugin/package.json index e826b26..b76390f 100644 --- a/examples/symbolPlugin/package.json +++ b/examples/symbolPlugin/package.json @@ -1,8 +1,8 @@ { "name": "@examples/symbol-plugin", "private": true, - "main": "./dist/index.js", - "types": "./dist/index.d.ts", + "main": "./dist/main.js", + "types": "./dist/main.d.ts", "scripts": { "build": "tsc -p tsconfig.prod.json", "compile": "tsc" diff --git a/examples/symbolPlugin/src/index.ts b/examples/symbolPlugin/src/main.ts similarity index 100% rename from examples/symbolPlugin/src/index.ts rename to examples/symbolPlugin/src/main.ts diff --git a/packages/core/README.md b/packages/core/README.md index b499e24..f43f09f 100644 --- a/packages/core/README.md +++ b/packages/core/README.md @@ -188,7 +188,7 @@ declare module "@assertive-ts/core" { } ``` -> **Note:** 3rd-party libraries should do this on their types entry point (index.d.ts), this way the interface is automatically extended when their plugin is passed to the `usePlugin(..)` function. +> **Note:** 3rd-party libraries should do this on their types entry point (e.g. main.d.ts), this way the interface is automatically extended when their plugin is passed to the `usePlugin(..)` function. ### How to... diff --git a/packages/core/package.json b/packages/core/package.json index ffa5aad..4c39c70 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -13,8 +13,8 @@ "type-safety", "typescript" ], - "main": "./dist/index.js", - "types": "./dist/index.d.ts", + "main": "./dist/main.js", + "types": "./dist/main.d.ts", "files": [ "dist/", "src/" diff --git a/packages/core/src/index.ts b/packages/core/src/main.ts similarity index 100% rename from packages/core/src/index.ts rename to packages/core/src/main.ts diff --git a/packages/core/test/lib/ArrayAssertion.test.ts b/packages/core/test/lib/ArrayAssertion.test.ts index 34dbc21..9be879b 100644 --- a/packages/core/test/lib/ArrayAssertion.test.ts +++ b/packages/core/test/lib/ArrayAssertion.test.ts @@ -1,8 +1,8 @@ -import { expect } from "../../src"; import { ArrayAssertion } from "../../src/lib/ArrayAssertion"; import { NumberAssertion } from "../../src/lib/NumberAssertion"; import { UnsupportedOperationError } from "../../src/lib/errors/UnsupportedOperationError"; import { TypeFactories } from "../../src/lib/helpers/TypeFactories"; +import { expect } from "../../src/main"; import assert, { AssertionError } from "assert"; diff --git a/packages/core/test/lib/expect.test.ts b/packages/core/test/lib/expect.test.ts index 90f2bf0..0306fd6 100644 --- a/packages/core/test/lib/expect.test.ts +++ b/packages/core/test/lib/expect.test.ts @@ -1,4 +1,3 @@ -import { expect } from "../../src"; import { ArrayAssertion } from "../../src/lib/ArrayAssertion"; import { Assertion } from "../../src/lib/Assertion"; import { BooleanAssertion } from "../../src/lib/BooleanAssertion"; @@ -9,6 +8,7 @@ import { NumberAssertion } from "../../src/lib/NumberAssertion"; import { ObjectAssertion } from "../../src/lib/ObjectAssertion"; import { PromiseAssertion } from "../../src/lib/PromiseAssertion"; import { StringAssertion } from "../../src/lib/StringAssertion"; +import { expect } from "../../src/main"; import assert from "assert"; diff --git a/packages/core/test/index.test.ts b/packages/core/test/main.test.ts similarity index 90% rename from packages/core/test/index.test.ts rename to packages/core/test/main.test.ts index c5addc2..c8a9730 100644 --- a/packages/core/test/index.test.ts +++ b/packages/core/test/main.test.ts @@ -1,8 +1,8 @@ -import { assert as libAssert, assertThat, expect, TypeFactories } from "../src"; +import { assert as libAssert, assertThat, expect, TypeFactories } from "../src/main"; import assert from "assert"; -describe("[Unit] index.test.ts", () => { +describe("[Unit] main.test.ts", () => { context("expect", () => { it("is exposed to the API", () => { assert.ok(expect); diff --git a/packages/core/typedoc.json b/packages/core/typedoc.json index 0dd22f5..c954fb5 100644 --- a/packages/core/typedoc.json +++ b/packages/core/typedoc.json @@ -1,7 +1,7 @@ { "$schema": "https://typedoc.org/schema.json", "cleanOutputDir": true, - "entryPoints": ["src/index.ts"], + "entryPoints": ["src/main.ts"], "entryPointStrategy": "expand", "gitRevision": "main", "githubPages": false,