fix(curriculum): update workshop instructions to clarify named exports with example. (#59190)

This commit is contained in:
agilan11
2025-03-10 17:20:38 +05:30
committed by GitHub
parent 924e9c6db4
commit e466ed93ad
@@ -14,7 +14,15 @@ All the CSS have been provided for you so you can focus on creating the navbar.
Start by defining a `Navbar` functional component that returns a pair of round parentheses. In the next step, you will start to build out the component using JSX.
Make sure to `export` the component, as it will be imported into the HTML file.
Make sure to use a named export when exporting the component, as it will be imported into the HTML file.
Here is an example of a named export:
```js
export function multiply(a, b) {
return a * b;
}
```
Also, React functional components need to start with a capital letter because it is a way to differentiate from regular HTML elements.