From 4c2b976147e5244401086f4347edf64227e30619 Mon Sep 17 00:00:00 2001 From: Ferdinand Thiessen Date: Wed, 13 Nov 2024 17:59:53 +0100 Subject: [PATCH] fix: typo in code guidelines Co-authored-by: Maksim Sukharev Signed-off-by: Ferdinand Thiessen --- developer_manual/digging_deeper/javascript-apis.rst | 7 ++++++- .../getting_started/coding_standards/html_css.rst | 6 +++--- .../getting_started/coding_standards/javascript.rst | 10 +++++----- 3 files changed, 14 insertions(+), 9 deletions(-) diff --git a/developer_manual/digging_deeper/javascript-apis.rst b/developer_manual/digging_deeper/javascript-apis.rst index 06251d10e..e48b2aa61 100644 --- a/developer_manual/digging_deeper/javascript-apis.rst +++ b/developer_manual/digging_deeper/javascript-apis.rst @@ -118,10 +118,15 @@ This package provides helpers to generate URLs, e.g. to access assets and REST A This package provides helpers interact with the Files sharing app, e.g. to detect if the current page is a public share and retrieving the sharing token. Documentation: https://nextcloud-libraries.github.io/nextcloud-sharing/ +.. _js-library_nextcloud-vue: + ``@nextcloud/vue`` ^^^^^^^^^^^^^^^^^^ -This package provides lots of nextcloud components allowing you to quickly build UIs. Documentation: https://nextcloud-vue-components.netlify.com/ +This package provides lots of Vue components allowing you to quickly build UIs in Nextcloud design. + +- Documentation: https://nextcloud-vue-components.netlify.app/ +- Source code: https://github.com/nextcloud-libraries/nextcloud-vue Events ------ diff --git a/developer_manual/getting_started/coding_standards/html_css.rst b/developer_manual/getting_started/coding_standards/html_css.rst index f3a223af5..20de48a46 100644 --- a/developer_manual/getting_started/coding_standards/html_css.rst +++ b/developer_manual/getting_started/coding_standards/html_css.rst @@ -8,7 +8,7 @@ HTML - HTML should be HTML5 compliant - Avoid more than one tag per line - Always indent blocks -- Try to avoid IDs inst +- Try to avoid IDs instead prefer classes. **DO** @@ -28,8 +28,8 @@ HTML CSS --- -- Do not bind your CSS to much to your HTML structure. -- Try to avoid IDs for query selectors but use classes. +- Do not bind your CSS too much to your HTML structure. +- Try to avoid using IDs and tags for query selectors, but use classes. - Try to make your CSS reusable by grouping common attributes into classes. - Take a look at the `Writing Tactical CSS & HTML `_ video on YouTube. diff --git a/developer_manual/getting_started/coding_standards/javascript.rst b/developer_manual/getting_started/coding_standards/javascript.rst index a16cc5a48..8732826a3 100644 --- a/developer_manual/getting_started/coding_standards/javascript.rst +++ b/developer_manual/getting_started/coding_standards/javascript.rst @@ -8,7 +8,7 @@ JavaScript and Typescript General rules and advices ------------------------- -- Nextcloud uses Vue.js for its interface, for a consistent user interface we recommend apps to also use Vue with the nextcloud provided components. +- Nextcloud uses Vue.js for its interface, for a consistent user interface we recommend apps to also use Vue with :ref:`provided components `. Yet also vanilla JavaScript and HTML can be used. - We recommend using Typescript for its type checking and improved static code analysis features. - Do not create global variables, instead if needed use global namespace objects like ``OCA.YourApp.…`` @@ -127,10 +127,10 @@ Naming and casing interface I_request { /* ... */ } type arguments = string[] -Indention -""""""""" +Indentation +""""""""""" -- Use tabs instead of spaces for indention - tab width is 4 spaces. +- Use tabs instead of spaces for indenting - tab width is 4 spaces. - You can align e.g. comments using spaces if needed. @@ -607,7 +607,7 @@ Objects const obj = { first: 1, - second: 2 - - second: 2, + + second: 2, + third: 3 }