Reputation: 30235
I have a strange problem when I comment out the dnxcore in the asp.net 5 (or a library) project. If I want to run only on .net framework (dnx), then I can delete the dnxcore from the project.json which works fine, but when I just comment it out there is an error that it's an illegal symbol:
Seems like a bug in VS or framework to me, is there any way to fix it?
P.S. I want to turn dnxcore off because the Azure Storage 6.0.0 does not support it, though I guess this is irrelevant to the question
Upvotes: 1
Views: 421
Reputation: 28425
The DNX json parser doesn't support comments. More details here: https://github.com/aspnet/Announcements/issues/24
Upvotes: 1
Reputation: 6932
Instead of commenting out the data, can you instead give it a different name?
...
"frameworks": {
"dnx451": {}
"//dnxcore50": {
"dependencies": {
...
The idea here being that since JSON doesn't support comments, you can change the name of the property and it will be ignored.
Upvotes: 0
Reputation: 30235
It seems that comments in json are not supported at all, so the bug here is that Visual Studio shows them in green as if it's real comment. More details on json comments in another post.
Upvotes: 0