Skip to content

Use Prettier for code formatting and implement Sass #11

@wnm210

Description

@wnm210

I propose implementing Sass and Prettier to this project. It would make things easier. Prettier is a code formatter, read more about it here. Sass is a stylesheet language that is compiled to CSS. It is really easy to use and saves you a lot of time when writing styling rules. Documentation: https://sass-lang.com/documentation/

Prettier is a great tool and it supports plenty of languages. You should also implement it to your other projects as the key feature of it is that there is no need to discuss style in code review.

Prettier configuration that I use

{
    "tabWidth": 4,
    "useTabs": false,
    "printWidth": 180,
    "singleQuote": true,
    "bracketSpacing": true,
    "bracketSameLine": true
}

Sass syntax

@mixin button-base()
    @include typography(button)
    @include ripple-surface
    @include ripple-radius-bounded

    display: inline-flex
    position: relative
    height: $button-height
    border: none
    vertical-align: middle

    &:hover
        cursor: pointer

    &:disabled
        color: $mdc-button-disabled-ink-color
        cursor: default
        pointer-events: none

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions