Browse Source

Removed initial code.

Frederic G. MARAND 5 years ago
parent
commit
84c4c29c8f
4 changed files with 3 additions and 15 deletions
  1. 0 9
      __tests__/base.spec.ts
  2. 2 1
      package.json
  3. 0 4
      src/index.ts
  4. 1 1
      tsconfig.json

+ 0 - 9
__tests__/base.spec.ts

@@ -2,17 +2,8 @@ import {
   BinaryOperation,
   BinaryOperators,
   evaluate,
-  sampleFunction,
 } from "../src";
 
-describe("This is a simple test", () => {
-  test("Check the sampleFunction function", () => {
-    const actual = sampleFunction("hello");
-    const expected = "hellohello";
-    expect(actual).toEqual(expected);
-  });
-});
-
 describe("Simple expression tests", () => {
   test("Check literal value", () => {
     expect(evaluate({ type: "literal", value: 5 })).toBeCloseTo(5);

+ 2 - 1
package.json

@@ -9,7 +9,7 @@
     "typescript": "^3.0.1"
   },
   "license": "MIT",
-  "main": "index.js",
+  "main": "lib/src/index.js",
   "name": "typescript",
   "private": false,
   "repository": "https://medium.com/@mtiller/debugging-with-typescript-jest-ts-jest-and-visual-studio-code-ef9ca8644132",
@@ -18,5 +18,6 @@
     "lint": "tslint -p tsconfig.json",
     "test": "jest"
   },
+  "typings": "lib/src/index.d.ts",
   "version": "1.0.0"
 }

+ 0 - 4
src/index.ts

@@ -1,6 +1,2 @@
-export function sampleFunction(x: string): string {
-  return x + x;
-}
-
 export * from "./core";
 export * from "./utils";

+ 1 - 1
tsconfig.json

@@ -9,7 +9,7 @@
     // "allowJs": true,                       /* Allow javascript files to be compiled. */
     // "checkJs": true,                       /* Report errors in .js files. */
     // "jsx": "preserve",                     /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */
-    // "declaration": true,                   /* Generates corresponding '.d.ts' file. */
+    "declaration": true,                      /* Generates corresponding '.d.ts' file. */
     // "declarationMap": true,                /* Generates a sourcemap for each corresponding '.d.ts' file. */
     // "sourceMap": true,                     /* Generates corresponding '.map' file. */
     // "outFile": "./",                       /* Concatenate and emit output to single file. */