Exercise 2 - Basics

Hello, everyone.
i am new here and i just started the Javascript Track

my question is revolved around the Basics exercise, i understand how it starts with Constants and Lets (probably no one is using vars anymore) but also vars, jumps into how a function is made.

and straight from that into exports, i finished the exercise itself but since jumping from functions into exports ive been stuck in a void of thinking, how it counts as basics?

i did not see any specs file and understood nothing of whats happening around me. is that something that persists across the whole track or something that is thrown at you in the beginning and never comes back again?

Hello :slight_smile:

Was there some code you had to write that you didn’t understand?

just the exports in general, the whole explanation and the usage felt confusing overall just that part.

Every exercise you will see on Exercism gets you to write some functions in a module. The tests import the module and invoke the functions in various ways. I suppose the author of the Basics concepts wanted to introduce exports right away because you’ll be seeing/using them over and over.

Did you have to write any exports though? From memory, you don’t have to.

There’s lots of code that’s used because it has to be to work, but unless we’re asking you to write it, you shouldn’t need to worry about it. It’ll be explained at a later stage.

That said, if you’re being expected to write functions from scratch and they’re using export and we don’t explain that, I’d think that should be improved. But I think the stub you’re provided with contains the functions predefined.

not much, the only export i needed to do per the assignment was a constant
and the stub was contained everything,

so from what i gathered i can just forget about it untill it appears again.
thank you both for the replay :)

1 Like