Skip to content

Commit

Permalink
Rename dev server legacy type to improve ergonomics
Browse files Browse the repository at this point in the history
  • Loading branch information
cowboy committed Jan 28, 2022
1 parent 478dc10 commit 3a9100a
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 15 deletions.
6 changes: 3 additions & 3 deletions npm/react/plugins/babel/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Configuration } from "webpack";

declare namespace legacyDevServer {
declare namespace CypressBabelDevServer {
interface CypressBabelDevServerConfig {
/**
* Allows to adjust the webpackConfig that our dev-server will use
Expand Down Expand Up @@ -31,6 +31,6 @@ declare namespace legacyDevServer {
* @param config comes from the argument of the `pluginsFile` function
* @param devServerConfig additional config object (create an empty object it to see how to use it)
*/
declare function legacyDevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, devServerConfig?: legacyDevServer.CypressBabelDevServerConfig): void
declare function CypressBabelDevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, devServerConfig?: CypressBabelDevServer.CypressBabelDevServerConfig): void

export = legacyDevServer;
export = CypressBabelDevServer;
6 changes: 3 additions & 3 deletions npm/react/plugins/craco/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
declare namespace legacyDevServer {
declare namespace CypressCracoDevServer {
interface CypressCracoDevServerConfig {
/**
* The object exported of your craco.config.js file
Expand Down Expand Up @@ -27,6 +27,6 @@ declare namespace legacyDevServer {
* @param config comes from the argument of the `pluginsFile` function
* @param cracoConfig the object exported of your craco.config.js file
*/
declare function legacyDevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, cracoConfig: any): void
declare function CypressCracoDevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, cracoConfig: any): void

export = legacyDevServer;
export = CypressCracoDevServer;
6 changes: 3 additions & 3 deletions npm/react/plugins/load-webpack/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
declare namespace legacyDevServer {
declare namespace CypressWebpackDevServer {
interface CypressWebpackDevServerConfig {
/**
* Location of the weppack.config Cypress should use
Expand Down Expand Up @@ -27,6 +27,6 @@ declare namespace legacyDevServer {
* @param config comes from the argument of the `pluginsFile` function
* @param devServerConfig additional config object (create an empty object to see how to use it)
*/
declare function legacyDevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, devServerConfig?: legacyDevServer.CypressWebpackDevServerConfig): void
declare function CypressWebpackDevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, devServerConfig?: CypressWebpackDevServer.CypressWebpackDevServerConfig): void

export = legacyDevServer;
export = CypressWebpackDevServer;
6 changes: 3 additions & 3 deletions npm/react/plugins/next/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
declare namespace legacyDevServer {
declare namespace CypressNextDevServer {
interface CypressNextDevServerConfig {
/**
* Path to an index.html file that will serve as the template in
Expand All @@ -21,6 +21,6 @@ declare namespace legacyDevServer {
* @param config comes from the argument of the `pluginsFile` function
* @param devServerConfig additional config object (create an empty object to see how to use it)
*/
declare function legacyDevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, devServerConfig?: legacyDevServer.CypressNextDevServerConfig): void
declare function CypressNextDevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, devServerConfig?: CypressNextDevServer.CypressNextDevServerConfig): void

export = legacyDevServer;
export = CypressNextDevServer;
6 changes: 3 additions & 3 deletions npm/react/plugins/react-scripts/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
declare namespace legacyDevServer {
declare namespace CypressCRADevServer {
interface CypressCRADevServerConfig {
/**
* Location of the weppack.config Cypress should use
Expand Down Expand Up @@ -27,6 +27,6 @@ declare namespace legacyDevServer {
* @param config comes from the argument of the `pluginsFile` function
* @param devServerConfig additional config object (create an empty object to see how to use it)
*/
declare function legacyDevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, devServerConfig?: legacyDevServer.CypressCRADevServerConfig): void
declare function CypressCRADevServer(on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions, devServerConfig?: CypressCRADevServer.CypressCRADevServerConfig): void

export = legacyDevServer;
export = CypressCRADevServer;

0 comments on commit 3a9100a

Please sign in to comment.