-
Notifications
You must be signed in to change notification settings - Fork 8
friendly error messages
In addition to standard code editor features, netnet's editor also has a few extra features aimed at making it easier for beginners and artists to experiment with code, these include realtime editing, friendly error messages (this page), built in references and tidy code. netnet also provides a few different options for saving or sharing your work which fall under two categories, what we call sketches (quick single page works) and projects (works which include other files/assets and are hosted on GitHub)
Errors and bugs are a pretty standard part of the coding process and so various different tools exist for different programming languages to help identify where and what the issue might be so that you can more efficiently debug your code. Most of these tools display error messages using coding lingo which can be alienating for beginners. Even more frustrating is the fact that bugs in HTML and CSS (unlike JavaScript) don't typically return error messages at all (which is something we discuss in a couple of our tutorials).
For this reason we've created a friendly error system for translating common errors into more beginner friendly language, not just for JavaScript errors but for HTML and CSS as well! When netnet notices a mistake in your code it will mark the line the mistake appears on with a red or orange dot, whether it's a technical error or not (sometimes the browser can fix your mistakes, but we don't want you to develop bad practices, so we point these out too!). When you click on that dot netnet will explain what the mistake it thinks you made in plain English (more or less). Like all error spotting tools, netnet will always know when you made a mistake, but it might not be 100% correct on exactly where or what that mistake is.
When explaining a potential bug in your code, netnet will also give you the option to launch the Code Review widget (which can also be found in the my sketch or my proejct section of the Functions Menu), this widget looks a lot more like something you'd find in professional developer tools, it displays all your errors in the same list written in programmer lingo. As we mentioned before, netnet isn't here to replace standard tools, it's here to help you get started. For this reason we think it's helpful to use this Code Review widget to start getting accustomed to the way these errors might normally look in standard tools. But don't worry, netnet can still translate these errors into friendlier langauge for you by clicking the line number links that appear above each of the error messages in the Code Review widget.