Skip to content

Commit 68b3b5e

Browse files
committed
fix: fix homepage Plugin example
1 parent 476351b commit 68b3b5e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/pages/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,15 +81,15 @@ const textContents = {
8181
`,
8282
customizableCode: `
8383
class MyPlugin {
84-
constructor(mocksServer) {
85-
mocksServer.addSetting({
84+
constructor({ core, config }) {
85+
this._option = config.addOption({
8686
name: "traceMocks",
8787
type: "boolean",
8888
description: "Trace mocks changes",
8989
default: true
9090
});
9191
92-
mocksServer.onChangeMocks(this._onChangeMocks.bind(this))
92+
core.onChangeMocks(this._onChangeMocks.bind(this))
9393
}
9494
// ...
9595
}

0 commit comments

Comments
 (0)