0

For example: import { createDrawerNavigator } from '@react-navigation/drawer';

What is the significance of the '@'?

I tried looking it up but the answers explained its usage as a pointer to the root directory. (as explained here.)

can-ishk
  • 3
  • 3
  • 1
    Did you read this about npm namespaces? https://stackoverflow.com/questions/36667258/what-is-the-meaning-of-the-at-prefix-on-npm-packages – sinanspd Mar 17 '23 at 02:16
  • @sinanspd no, I didn't come across that. Thanks! I get it now. – can-ishk Mar 17 '23 at 02:31

1 Answers1

0

NPM packages are sometimes published under a "scope".

When used in package names, scopes are prefixed with @. So drawer in the react-navigation scope is published as @react-navigation/drawer.

See https://docs.npmjs.com/cli/using-npm/scope for more information.

David Neil
  • 61
  • 3