Skip to content

Commit

Permalink
Add some missing exports in just-scripts (#745)
Browse files Browse the repository at this point in the history
* Add missing exports

* Change files

* Remove all other missing exports
  • Loading branch information
christiango committed Mar 4, 2024
1 parent 3cdc0dd commit a5a2fea
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 22 deletions.
11 changes: 11 additions & 0 deletions change/change-0bca84b5-bd0f-451d-ad22-717846a53e35.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"type": "patch",
"comment": "Export CssLoaderOptions and PrettierTaskOptions which both appear on the type signature for the public API of just-scripts",
"packageName": "just-scripts",
"email": "1581488+christiango@users.noreply.github.com",
"dependentChangeType": "patch"
}
]
}
21 changes: 5 additions & 16 deletions packages/just-scripts/etc/just-scripts.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,14 @@ export interface ApiExtractorOptions extends ApiExtractorTypes.IExtractorInvokeO
// @public
export function apiExtractorUpdateTask(options: ApiExtractorOptions): TaskFunction;

// Warning: (ae-forgotten-export) The symbol "Omit_2" needs to be exported by the entry point index.d.ts
//
// @public @deprecated (undocumented)
export function apiExtractorUpdateTask(configJsonFilePath: string, extractorOptions: Omit_2<ApiExtractorOptions, 'configJsonFilePath'>): TaskFunction;
export function apiExtractorUpdateTask(configJsonFilePath: string, extractorOptions: Omit<ApiExtractorOptions, 'configJsonFilePath'>): TaskFunction;

// @public (undocumented)
export function apiExtractorVerifyTask(options: ApiExtractorOptions): TaskFunction;

// @public @deprecated (undocumented)
export function apiExtractorVerifyTask(configJsonFilePath: string, extractorOptions: Omit_2<ApiExtractorOptions, 'configJsonFilePath'>): TaskFunction;
export function apiExtractorVerifyTask(configJsonFilePath: string, extractorOptions: Omit<ApiExtractorOptions, 'configJsonFilePath'>): TaskFunction;

// @public (undocumented)
export const basicWebpackConfig: Configuration;
Expand Down Expand Up @@ -128,16 +126,14 @@ export interface CreateOptions {
map?: (header: EntryHeader) => EntryHeader;
}

// Warning: (ae-forgotten-export) The symbol "CssLoaderOptions" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const createStylesOverlay: (options?: CssLoaderOptions) => Partial<Configuration>;

// @public
export function createTarTask(options?: CreateOptions): TaskFunction;

// @public (undocumented)
interface CssLoaderOptions {
export interface CssLoaderOptions {
// (undocumented)
localIdentName?: string;
// (undocumented)
Expand Down Expand Up @@ -304,19 +300,14 @@ export interface NodeExecTaskOptions {
tsconfig?: string;
}

// @public (undocumented)
type Omit_2<T, K extends keyof any> = Pick<T, Exclude<keyof T, K>>;

// Warning: (ae-forgotten-export) The symbol "PrettierTaskOptions" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export function prettierCheckTask(options?: PrettierTaskOptions): TaskFunction;

// @public (undocumented)
export function prettierTask(options?: PrettierTaskOptions): TaskFunction;

// @public (undocumented)
interface PrettierTaskOptions {
export interface PrettierTaskOptions {
// (undocumented)
configPath?: string;
// (undocumented)
Expand Down Expand Up @@ -453,13 +444,11 @@ export interface TsLoaderOptions {
transpileOnly: boolean;
}

// Warning: (ae-forgotten-export) The symbol "TsOverlayOptions" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const tsOverlay: (overlayOptions?: TsOverlayOptions | undefined) => Partial<Configuration>;

// @public (undocumented)
interface TsOverlayOptions {
export interface TsOverlayOptions {
// (undocumented)
checkerOptions?: Partial<TsCheckerOptions>;
// (undocumented)
Expand Down
6 changes: 4 additions & 2 deletions packages/just-scripts/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ export * from './webpack/webpack.config';
export * from './webpack/webpack.serve.config';

// Webpack configs and overlays
import { tsOverlay, TsCheckerOptions, TsLoaderOptions } from './webpack/overlays/tsOverlay';
import { tsOverlay, TsCheckerOptions, TsLoaderOptions, TsOverlayOptions } from './webpack/overlays/tsOverlay';
import { htmlOverlay } from './webpack/overlays/htmlOverlay';
import { stylesOverlay, createStylesOverlay } from './webpack/overlays/stylesOverlay';
import { stylesOverlay, createStylesOverlay, CssLoaderOptions } from './webpack/overlays/stylesOverlay';
import { fileOverlay } from './webpack/overlays/fileOverlay';
import { displayBailoutOverlay } from './webpack/overlays/displayBailoutOverlay';

Expand All @@ -28,8 +28,10 @@ export {
fileOverlay,
displayBailoutOverlay,
createStylesOverlay,
CssLoaderOptions,
TsCheckerOptions,
TsLoaderOptions,
TsOverlayOptions,
};

import * as webpackMerge from 'webpack-merge';
Expand Down
2 changes: 0 additions & 2 deletions packages/just-scripts/src/tasks/apiExtractorTask.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ interface ApiExtractorContext {
apiExtractorModule: typeof ApiExtractorTypes;
}

type Omit<T, K extends keyof any> = Pick<T, Exclude<keyof T, K>>;

export function apiExtractorVerifyTask(options: ApiExtractorOptions): TaskFunction;
/** @deprecated Use object param version */
export function apiExtractorVerifyTask(
Expand Down
2 changes: 1 addition & 1 deletion packages/just-scripts/src/tasks/prettierTask.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ interface PrettierContext {
check: boolean;
}

interface PrettierTaskOptions {
export interface PrettierTaskOptions {
files?: string[] | string;
ignorePath?: string;
configPath?: string;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const sassTest = /\.(scss|sass)$/;
const sassModuleTest = /\.module\.(scss|sass)$/;
const defaultIdentName = '[name]_[local]_[hash:base64:5]';

interface CssLoaderOptions {
export interface CssLoaderOptions {
modules?: boolean;
localIdentName?: string;
}
Expand Down

0 comments on commit a5a2fea

Please sign in to comment.