Skip to content

JavaScript coding standards #113

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

Closed
wants to merge 3 commits into from

Conversation

cconard96
Copy link
Contributor

GLPI is written in multiple languages and while it is still predominately PHP, the amount of JavaScript has increased a lot in recent versions and in 10.0 there will be the introduction of Twig. Currently, the developer documentation focuses solely on the PHP side.

This PR is a start of adding in documentation for the other languages by splitting the coding standards documentation into a Global Coding Standards page which includes global standards like line length, and individual pages for each language/file type (PHP, JavaScript, etc). It does not include standards for Twig yet since its use is not in the master branch yet.

@trasher
Copy link
Collaborator

trasher commented Oct 4, 2021

The PHP part is going to be removed once we'll switch to PSR coding standards (planned just before the 10 release)

@cconard96
Copy link
Contributor Author

The PHP part is going to be removed once we'll switch to PSR coding standards (planned just before the 10 release)

Some of this info would still be relevant such as requiring PHP files to have a ".class.php" ending because of the custom autoloader and the warning(s) about using namespaces unless we implement a PSR-4 autoloader and somehow fix namespace support.

@cconard96
Copy link
Contributor Author

Rebased to incorporate the PSR-12 change

@cedric-anne
Copy link
Member

Is this still relevant to document coding standards ? We should probably only document the lint tools we use and how to integrate them with a set of IDEs we are using in the GLPI core team.

@trasher
Copy link
Collaborator

trasher commented Jun 2, 2025

Is this still relevant to document coding standards ?

I guess not; we can drop this.

@cconard96
Copy link
Contributor Author

Is this still relevant to document coding standards ? We should probably only document the lint tools we use and how to integrate them with a set of IDEs we are using in the GLPI core team.

I don't think this is needed anymore

@cedric-anne cedric-anne closed this Jun 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants