File tree Expand file tree Collapse file tree 3 files changed +39
-1
lines changed
Expand file tree Collapse file tree 3 files changed +39
-1
lines changed Original file line number Diff line number Diff line change 1616 " loud-rivers-pretend" ,
1717 " many-spies-fix" ,
1818 " rude-berries-rescue" ,
19+ " rude-pets-hope" ,
1920 " shy-turkeys-count" ,
2021 " silly-seas-impress" ,
2122 " swift-planets-rescue" ,
Original file line number Diff line number Diff line change 11# @heymp/scratchpad
22
3+ ## 1.0.0-next.11
4+
5+ ### Minor Changes
6+
7+ - 708f25e: Support ts config files
8+
9+ ` scratchpad.config.ts `
10+
11+ ``` ts
12+ import { Config } from " @heymp/scratchpad/src/config.js" ;
13+
14+ export function hi(name : string ) {
15+ console .log (` Hi there ${name } ` );
16+ }
17+
18+ declare global {
19+ interface Window {
20+ hi: typeof hi ;
21+ }
22+ }
23+
24+ export default {
25+ playwright : async (args ) => {
26+ const { context } = args ;
27+ await context .exposeFunction (" hi" , hi );
28+ },
29+ } satisfies Config ;
30+ ```
31+
32+ ` test.ts `
33+
34+ ``` .ts
35+ // / <reference path="./scratchpad.config.ts" />
36+
37+ window .hi (' Bob' );
38+ ```
39+
340## 1.0.0-next.10
441
542### Patch Changes
Original file line number Diff line number Diff line change 11{
22 "name" : " @heymp/scratchpad" ,
33 "description" : " Run TS/JS snippets in a locally" ,
4- "version" : " 1.0.0-next.10 " ,
4+ "version" : " 1.0.0-next.11 " ,
55 "main" : " bin/cli.js" ,
66 "type" : " module" ,
77 "bin" : {
You can’t perform that action at this time.
0 commit comments