Skip to content

Commit 508f9eb

Browse files
committed
feature #8 Add typescript types (chapterjason)
This PR was squashed before being merged into the main branch. Discussion ---------- Add typescript types Hope this is enough. Tested with yarn link: <img width="938" alt="Screenshot 2020-12-11 at 9 37 21 PM" src="https://user-images.githubusercontent.com/1337562/101952506-0f07d880-3bf9-11eb-8e6c-536c48664798.png"> Fixes: #7 Commits ------- ec0f1ba Add typescript types
2 parents 6696ed4 + ec0f1ba commit 508f9eb

File tree

2 files changed

+34
-0
lines changed

2 files changed

+34
-0
lines changed

types/index.d.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
/*
2+
* This file is part of the Symfony package.
3+
*
4+
* (c) Fabien Potencier <[email protected]>
5+
*
6+
* For the full copyright and license information, please view the LICENSE
7+
* file that was distributed with this source code.
8+
*/
9+
10+
import { Application } from "stimulus";
11+
12+
declare module "@symfony/stimulus-bridge" {
13+
14+
export function startStimulusApp(context: __WebpackModuleApi.RequireContext): Application;
15+
16+
}

types/package.json

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"name": "@symfony-types/stimulus-bridge",
3+
"description": "Types for the Symfony Stimulus integration bridge",
4+
"version": "1.0.0",
5+
"license": "MIT",
6+
"types": "index.d.ts",
7+
"repository": {
8+
"type": "git",
9+
"url": "https://github.com/symfony/stimulus-bridge.git",
10+
"directory": "types"
11+
},
12+
"dependencies": {
13+
"@types/webpack-env": "^1.16.0"
14+
},
15+
"files": [
16+
"index.d.ts"
17+
]
18+
}

0 commit comments

Comments
 (0)