@teambit/bundler 1.0.226 → 1.0.227
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/artifacts/__bit_junit.xml +1 -1
- package/artifacts/preview/teambit_compilation_bundler-preview.js +1 -1
- package/artifacts/schema.json +70 -229
- package/dist/{preview-1712632644937.js → preview-1712719054377.js} +2 -2
- package/package.json +10 -10
- package/tsconfig.json +22 -1
- package/dist/browser-runtime.d.ts +0 -4
- package/dist/bundle.d.ts +0 -4
- package/dist/bundler-context.d.ts +0 -207
- package/dist/bundler.aspect.d.ts +0 -2
- package/dist/bundler.composition.d.ts +0 -1
- package/dist/bundler.d.ts +0 -74
- package/dist/bundler.main.runtime.d.ts +0 -102
- package/dist/bundler.service.d.ts +0 -11
- package/dist/component-server.d.ts +0 -55
- package/dist/dedup-envs.d.ts +0 -12
- package/dist/dev-server-context.d.ts +0 -47
- package/dist/dev-server.d.ts +0 -45
- package/dist/dev-server.graphql.d.ts +0 -3
- package/dist/dev-server.service.d.ts +0 -67
- package/dist/events/components-server-started-event.d.ts +0 -18
- package/dist/events/index.d.ts +0 -1
- package/dist/exceptions/bind-error.d.ts +0 -2
- package/dist/exceptions/index.d.ts +0 -1
- package/dist/get-entry.d.ts +0 -14
- package/dist/index.d.ts +0 -10
- package/dist/select-port.d.ts +0 -4
@@ -1,67 +0,0 @@
|
|
1
|
-
import { EnvService, ExecutionContext, EnvDefinition, Env, EnvContext, ServiceTransformationMap } from '@teambit/envs';
|
2
|
-
import { PubsubMain } from '@teambit/pubsub';
|
3
|
-
import { DependencyResolverMain } from '@teambit/dependency-resolver';
|
4
|
-
import { BrowserRuntimeSlot, DevServerTransformerSlot } from './bundler.main.runtime';
|
5
|
-
import { ComponentServer } from './component-server';
|
6
|
-
import { DevServer } from './dev-server';
|
7
|
-
import { DevServerContext } from './dev-server-context';
|
8
|
-
export type DevServerServiceOptions = {
|
9
|
-
dedicatedEnvDevServers?: string[];
|
10
|
-
};
|
11
|
-
type DevServiceTransformationMap = ServiceTransformationMap & {
|
12
|
-
/**
|
13
|
-
* Required for `bit start`
|
14
|
-
*/
|
15
|
-
getDevEnvId?: (context?: any) => string;
|
16
|
-
/**
|
17
|
-
* Returns and configures the dev server
|
18
|
-
* Required for `bit start`
|
19
|
-
*/
|
20
|
-
getDevServer?: (context: DevServerContext) => DevServer | Promise<DevServer>;
|
21
|
-
};
|
22
|
-
export type DevServerDescriptor = {
|
23
|
-
/**
|
24
|
-
* id of the dev server (e.g. webpack)
|
25
|
-
*/
|
26
|
-
id: string;
|
27
|
-
/**
|
28
|
-
* display name of the dev server (e.g. Webpack dev server)
|
29
|
-
*/
|
30
|
-
displayName: string;
|
31
|
-
/**
|
32
|
-
* icon of the configured dev server.
|
33
|
-
*/
|
34
|
-
icon: string;
|
35
|
-
/**
|
36
|
-
* string containing the config for display.
|
37
|
-
*/
|
38
|
-
config: string;
|
39
|
-
version?: string;
|
40
|
-
};
|
41
|
-
export declare class DevServerService implements EnvService<ComponentServer, DevServerDescriptor> {
|
42
|
-
private pubsub;
|
43
|
-
private dependencyResolver;
|
44
|
-
/**
|
45
|
-
* browser runtime slot
|
46
|
-
*/
|
47
|
-
private runtimeSlot;
|
48
|
-
private devServerTransformerSlot;
|
49
|
-
name: string;
|
50
|
-
constructor(pubsub: PubsubMain, dependencyResolver: DependencyResolverMain,
|
51
|
-
/**
|
52
|
-
* browser runtime slot
|
53
|
-
*/
|
54
|
-
runtimeSlot: BrowserRuntimeSlot, devServerTransformerSlot: DevServerTransformerSlot);
|
55
|
-
render(env: EnvDefinition, context: ExecutionContext[]): Promise<string>;
|
56
|
-
getDescriptor(environment: EnvDefinition, context?: ExecutionContext[]): Promise<DevServerDescriptor | undefined>;
|
57
|
-
transform(env: Env, envContext: EnvContext): DevServiceTransformationMap | undefined;
|
58
|
-
runOnce(contexts: ExecutionContext[], { dedicatedEnvDevServers }: DevServerServiceOptions): Promise<ComponentServer[]>;
|
59
|
-
mergeContext(): void;
|
60
|
-
private getComponentsFromContexts;
|
61
|
-
/**
|
62
|
-
* builds the execution context for the dev server.
|
63
|
-
*/
|
64
|
-
private buildContext;
|
65
|
-
private transformDevServer;
|
66
|
-
}
|
67
|
-
export {};
|
@@ -1,18 +0,0 @@
|
|
1
|
-
import { BitBaseEvent } from '@teambit/pubsub';
|
2
|
-
declare class ComponentsServerStartedEventData {
|
3
|
-
readonly componentsServer: any;
|
4
|
-
readonly context: any;
|
5
|
-
readonly hostname: any;
|
6
|
-
readonly port: any;
|
7
|
-
constructor(componentsServer: any, context: any, hostname: any, port: any);
|
8
|
-
}
|
9
|
-
export declare class ComponentsServerStartedEvent extends BitBaseEvent<ComponentsServerStartedEventData> {
|
10
|
-
readonly timestamp: any;
|
11
|
-
readonly componentsServer: any;
|
12
|
-
readonly context: any;
|
13
|
-
readonly hostname: any;
|
14
|
-
readonly port: any;
|
15
|
-
static readonly TYPE = "components-server-started";
|
16
|
-
constructor(timestamp: any, componentsServer: any, context: any, hostname: any, port: any);
|
17
|
-
}
|
18
|
-
export {};
|
package/dist/events/index.d.ts
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
export * from './components-server-started-event';
|
@@ -1 +0,0 @@
|
|
1
|
-
export { BindError } from './bind-error';
|
package/dist/get-entry.d.ts
DELETED
@@ -1,14 +0,0 @@
|
|
1
|
-
import { ComponentID } from '@teambit/component';
|
2
|
-
import { ExecutionContext } from '@teambit/envs';
|
3
|
-
import { GetBitMapComponentOptions } from '@teambit/legacy/dist/consumer/bit-map/bit-map';
|
4
|
-
import { PathOsBased } from '@teambit/legacy/dist/utils/path';
|
5
|
-
import { BrowserRuntimeSlot } from './bundler.main.runtime';
|
6
|
-
export type ComponentDir = {
|
7
|
-
componentDir?: (componentId: ComponentID, bitMapOptions?: GetBitMapComponentOptions, options?: {
|
8
|
-
relative: boolean;
|
9
|
-
}) => PathOsBased | undefined;
|
10
|
-
};
|
11
|
-
/**
|
12
|
-
* computes the bundler entry.
|
13
|
-
*/
|
14
|
-
export declare function getEntry(context: ExecutionContext, runtimeSlot: BrowserRuntimeSlot): Promise<string[]>;
|
package/dist/index.d.ts
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
import { BundlerAspect } from './bundler.aspect';
|
2
|
-
export type { DevServer } from './dev-server';
|
3
|
-
export type { DevServerContext } from './dev-server-context';
|
4
|
-
export type { BundlerContext, Target, ModuleTarget, HtmlConfig as BundlerHtmlConfig, EntryMap as BundlerEntryMap, Entry as BundlerEntry, MetaData as BundlerContextMetaData, } from './bundler-context';
|
5
|
-
export type { Bundler, BundlerResult, BundlerMode, Asset, ChunksAssetsMap, EntriesAssetsMap, EntryAssets, } from './bundler';
|
6
|
-
export type { BundlerMain } from './bundler.main.runtime';
|
7
|
-
export type { ComponentDir } from './get-entry';
|
8
|
-
export { ComponentServer } from './component-server';
|
9
|
-
export * from './events';
|
10
|
-
export { BundlerAspect, BundlerAspect as default };
|
package/dist/select-port.d.ts
DELETED