Skip to content

Commit 1810413

Browse files
committed
Add feature.page API
1 parent c70a596 commit 1810413

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

api/feature/index.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,10 @@ export default function (data) {
77
feature.self = self(data.id);
88
feature.traps = traps()
99
feature.auth = auth()
10+
feature.page = {
11+
appendToSharedSpace: ScratchTools.appendToSharedSpace,
12+
waitForElement: ScratchTools.waitForElement,
13+
waitForElements: ScratchTools.waitForElements,
14+
}
1015
return feature;
1116
}

features/profile-flag/script.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
export default async function ({ feature, console }) {
2+
window.feature = feature
23
const locationElement = await ScratchTools.waitForElement(
34
"p.profile-details > span.location"
45
);

0 commit comments

Comments
 (0)