JuiceMind / JuiceMind

5 stars 0 forks source link

Add autoformat functionality for source files #281

Open mjdargen opened 3 months ago

mjdargen commented 3 months ago

Most modern editors do this, and it makes it a lot easier to read student code (they don't always follow instructions about formatting).


SN: Replit had a “Format Code” button that helped students struggling with code readability by restoring proper formatting. This feature would be incredibly useful for our students.


PC: It would be nice to have a format button to format the code

juicemind-dev commented 3 months ago

Yes definitely. We were wondering, as a teacher, do you like the idea that students can leverage the auto formatting (they don't have to remember correct formatting because the system does it automatically for them)? I think that's the main reason we have been a bit reluctant to add this feature.

mjdargen commented 3 months ago

I could see this varying from teacher to teacher. Personally, I like my students to have the option. I encourage them to follow proper formatting, but then use it at the end to double-check. It exists in all modern editors, and they will use it moving forward outside the class.

juicemind-dev commented 3 months ago

Yes, good point. I think we will make it the default on save and add a little button at the top right where they can format their code.

In the future we will add a setting from the teacher side to allow/disallow formatting from the student side.