-
-
Notifications
You must be signed in to change notification settings - Fork 7.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Symbol in the module exports array causes fatal error #1246
Comments
Nest doesn't support using Symbol as a token yet. |
Nest supports symbols from 5.3.12 |
There is just a bug or missed functionality. I'll try to create PR for for this issue asap |
Oh, my bad then |
there is need just to update |
Anyhow, you should use |
I think this is depends on your project. In a case of |
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/for There's a big difference. Symbol.for('foo') === Symbol.for('foo'); // true
Symbol('foo') === Symbol('foo'); // false This is exactly the same behavior with |
Thanks for reporting! |
Published as 5.4.1 |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
I'm submitting a...
Current behavior
Currently it isn't possible to use symbol in the exports array.
An example:
The bug is not reproduced if you use the string instead of the symbol.
Seems like this is a bug in the
addExportedComponent()
method in the injector module (link).Current implementation of this method doesn't have a checking of the symbol token, just for the string token.
Expected behavior
Symbol token can be used in the exports section as well as the string token
Environment
The text was updated successfully, but these errors were encountered: