Code guidelines
Vue:
- Use a consistent code style throughout your project
- Use single-file components for better organization and modularity
- Use meaningful and descriptive names for your components, methods, and variables
- Avoid using global variables and properties
- Use v-bind instead of {{ }} to bind data to attributes
- Use v-on instead of @ to bind event listeners
- Use computed properties to perform calculations and transformations on data
- Use watchers to perform actions when data changes
- Use Vuex to manage state across your application
- Use Vue Router to handle navigation within your application
- Following these guidelines will help keep your code organized, maintainable, and easier to understand and collaborate with other developers
Markdown:
- Use the # symbol to create headings, with one # representing the largest heading and six #s representing the smallest heading.
- Use * or - to create unordered lists and 1. to create ordered lists.
- Use ** to make text bold and * to make it italic.
- Use > to create blockquotes.
- Use backticks (`) to indicate code inline and triple backticks to create a code block.
- Use text to create hyperlinks.
- Use --- or *** to create horizontal rules.
- Use
to embed images.
- Make sure to leave a blank line between paragraphs.
- Preview your Markdown to ensure it renders correctly.
CSS:
- Use a consistent naming convention for CSS selectors.
- Organize your CSS code into sections, with comments to indicate the purpose of each section.
- Use whitespace and indentation to make your code more readable.
- Avoid using IDs in your CSS selectors, as they can lead to specificity issues.
- Use shorthand properties where possible to reduce the amount of code you need to write.
- Avoid using !important, as it can make your code harder to maintain.
- Use CSS preprocessors like Sass or Less to make your code more modular and easier to maintain.
- Use browser prefixes when necessary to ensure cross-browser compatibility.
- Minimize the use of global styles and use more specific selectors instead.
- Use media queries to create responsive designs that adapt to different screen sizes.