Web editor indentation #6

Closed
opened 2025-11-02 03:03:10 -06:00 by GiteaMirror · 6 comments
Owner

Originally created by @joubertredrat on GitHub (Nov 2, 2016).

Now with web editor working fine, I think that is necessary to set configurations by default or defined by user for better experience with web editor.

On PHP, javascript and I think that Go (Unknwon talk me if I'm wrong) we prefer 4 spaces indentation.
However, HTML and CSS developers normally prefer 2 spaces indentation. Have cases on other developers prefer tabulation instead spaces.

Because this I think that web editor can be configurable, one good example for this is on Bitbucket, you can set options in own editor.

screenshot-bitbucket org 2016-09-06 13-25-57

Or this configuration can be defined on user settings on only on admin area.

What you think guys?

Reference: https://github.com/gogits/gogs/issues/3460#issuecomment-242807939
Reference: https://github.com/gogits/gogs/issues/3610

--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/38896626-web-editor-indentation?utm_campaign=plugin&utm_content=tracker%2F47456670&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F47456670&utm_medium=issues&utm_source=github).
Originally created by @joubertredrat on GitHub (Nov 2, 2016). Now with web editor working fine, I think that is necessary to set configurations by default or defined by user for better experience with web editor. On PHP, javascript and I think that Go (Unknwon talk me if I'm wrong) we prefer 4 spaces indentation. However, HTML and CSS developers normally prefer 2 spaces indentation. Have cases on other developers prefer tabulation instead spaces. Because this I think that web editor can be configurable, one good example for this is on Bitbucket, you can set options in own editor. ![screenshot-bitbucket org 2016-09-06 13-25-57](https://cloud.githubusercontent.com/assets/1520407/18281998/8599e9a6-7435-11e6-94a4-bc4492e2ee33.png) Or this configuration can be defined on user settings on only on admin area. What you think guys? Reference: https://github.com/gogits/gogs/issues/3460#issuecomment-242807939 Reference: https://github.com/gogits/gogs/issues/3610 <bountysource-plugin> --- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/38896626-web-editor-indentation?utm_campaign=plugin&utm_content=tracker%2F47456670&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F47456670&utm_medium=issues&utm_source=github). </bountysource-plugin>
GiteaMirror added the topic/uitype/enhancementissue/stale labels 2025-11-02 03:03:10 -06:00
Author
Owner

@metalmatze commented on GitHub (Nov 2, 2016):

gofmt uses tabs and one tab equals 8 spaces.
https://golang.org/cmd/gofmt/
I really like the idea to make it customizable!

@metalmatze commented on GitHub (Nov 2, 2016): `gofmt` uses tabs and one tab equals 8 spaces. https://golang.org/cmd/gofmt/ I really like the idea to make it customizable!
Author
Owner

@silverwind commented on GitHub (Nov 18, 2016):

Customization options could be saved to localStorage on the client, but the defaults should come from the repository's .editorconfig.

@silverwind commented on GitHub (Nov 18, 2016): Customization options could be saved to `localStorage` on the client, but the defaults should come from the repository's `.editorconfig`.
Author
Owner

@pgaskin commented on GitHub (Mar 15, 2017):

What would be the scope of the saved changes? The repo? The filetype? The filepath? The session?

@pgaskin commented on GitHub (Mar 15, 2017): What would be the scope of the saved changes? The repo? The filetype? The filepath? The session?
Author
Owner

@silverwind commented on GitHub (Mar 15, 2017):

I'd say per-user options are sufficient. If you want finer control, you're better of placing a .editorconfig in the repo.

@silverwind commented on GitHub (Mar 15, 2017): I'd say per-user options are sufficient. If you want finer control, you're better of placing a `.editorconfig` in the repo.
Author
Owner

@stale[bot] commented on GitHub (Feb 4, 2019):

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions.

@stale[bot] commented on GitHub (Feb 4, 2019): This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions.
Author
Owner

@stale[bot] commented on GitHub (Feb 19, 2019):

This issue has been automatically closed because of inactivity. You can re-open it if needed.

@stale[bot] commented on GitHub (Feb 19, 2019): This issue has been automatically closed because of inactivity. You can re-open it if needed.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#6