Niedzielski has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/375100 )

Change subject: Chore: permit JavaScript compilation
......................................................................

Chore: permit JavaScript compilation

All our tooling is currently configured to support JavaScript files
except the compiler. Add the appropriate settings for consistency.
Also, fix some code snippet markdown to use TypeScript instead of
JavaScript.

Change-Id: I0b55b67b288d2e346cd5dbe7b9fa447b019ba3ab
---
M docs/development.md
M tsconfig.json
2 files changed, 8 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/marvin refs/changes/00/375100/1

diff --git a/docs/development.md b/docs/development.md
index df8208b..4505a5c 100644
--- a/docs/development.md
+++ b/docs/development.md
@@ -73,7 +73,7 @@
 third are preferred:
 
 1. Explicitly over-typed (right-hand typing is internal):
-    ```js
+    ```ts
     const app: FunctionalComponent<any> = (_props: any): JSX.Element =>
       <div class="App">Hello world</div>;
 
@@ -81,7 +81,7 @@
     ```
 
 2. **Preferred** - Explicitly typed (declared syntax):
-    ```js
+    ```ts
     const app: FunctionalComponent<any> = () =>
       <div class="App">Hello world</div>;
 
@@ -89,13 +89,13 @@
     ```
 
 3. **Preferred** - Explicitly typed (inline syntax):
-    ```js
+    ```ts
     export default (_props: any): JSX.Element =>
       <div class="App">Hello world</div>;
     ```
 
 4. Implicitly typed:
-    ```js
+    ```ts
     export default () =>
       <div class="App">Hello world</div>;
     ```
@@ -103,14 +103,14 @@
 The following are possible internal implementations but the second is 
preferred:
 
 1. Explicitly typed lambda:
-    ```js
+    ```ts
     server.get("*", (_request: express.Request, response: express.Response) => 
{
       response.status(404).send("Not found");
     });
     ```
 
 2. **Preferred** - Implicitly typed lambda:
-    ```js
+    ```ts
     server.get("*", (_request, response) => {
       response.status(404).send("Not found");
     });
diff --git a/tsconfig.json b/tsconfig.json
index 2eb0745..4d3ea6e 100644
--- a/tsconfig.json
+++ b/tsconfig.json
@@ -13,6 +13,8 @@
     "jsxFactory": "h",
     "moduleResolution": "node",
     "sourceMap": true,
+    "allowJs": true,
+    "checkJs": true,
 
     "strict": true,
 

-- 
To view, visit https://gerrit.wikimedia.org/r/375100
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0b55b67b288d2e346cd5dbe7b9fa447b019ba3ab
Gerrit-PatchSet: 1
Gerrit-Project: marvin
Gerrit-Branch: master
Gerrit-Owner: Niedzielski <[email protected]>
Gerrit-Reviewer: Sniedzielski <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to