This is more related to JavaScript (although the context is React function components).
const Users = () => {
//....
}
export default Users;
function Users() {
//...
}
export default Users;
export default function Users(){
//...
}
// Usage with auto-complete
import Users from './Users.js';
The export effect is the same, although there is a difference between functions and arrow functions.
But using export like so we do have a more significant difference:
// Bad practice, don't do it!
// No auto-complete, no function name while debugging
export default () => {
// Users logic
//...
}
// No auto complete on typing Users, need to name the default export
import MyUsers from './Users.js';