You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Then search for intresting challenge, for example `prime-number`.
25
-
Read the `README.md` in that folder. Write you solution in this folder.
24
+
then install all dependencies
25
+
26
+
for npm
27
+
28
+
```
29
+
npm install
30
+
```
26
31
27
-
At the end of your file export your function
32
+
or yarn
28
33
29
34
```
30
-
module.exports = name_of_your_function
35
+
yarn install
31
36
```
32
37
33
-
Go to folder `__tests__` in that folder, there will be test file (named in our example `isPrime.spec.js`). Change the first line from
38
+
Then search for intresting challenge, for example `prime-number`.
39
+
Read the `README.md` in that folder. Write you solution in javascript file dedicated to this folder (in our case `isPrime.js`). There is special place dedicated for that.
40
+
41
+
If you're sure it's all good, go to `__tests__` folder and open test file. Remove `.skip` method in tests and save.
42
+
43
+
Run tests by npm
34
44
35
45
```
36
-
const isPrime = require('../isPrime')
46
+
npm run prime-number
37
47
```
38
48
39
-
to
49
+
or if you're using yarn
40
50
41
51
```
42
-
const isPrime = require('../name_of_your_file')
52
+
yarn run prime-number
43
53
```
44
54
55
+
**If you take other task to do just use name of task folder instead of `prime-number`.**
0 commit comments