JSPM

css-grid-pf2tw

1.0.0
    • ESM via JSPM
    • ES Module Entrypoint
    • Export Map
    • Keywords
    • License
    • Repository URL
    • TypeScript Types
    • README
    • Created
    • Published
    • 0
    • Score
      100M100P100Q15696F
    • License MIT

    A package to migrate Primeflex CSS classes related to the 'grid system' to Tailwind CSS flexbox utilities.

    Package Exports

    • css-grid-pf2tw
    • css-grid-pf2tw/index.ts

    This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (css-grid-pf2tw) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

    Readme

    CSS migration tool from Primeflex "Grid system" to TailwindCSS

    This tool is meant for Angular projects that use the Primeflex "Grid system". It should be used before the CSS is migrated with primeclt pf2tw as otherwise the class names will already be renamed and then likely not be found.

    How to use:

    • install the package
    npm i css-grid-pf2tw
    • run the migrate command
    npx css-grid-pf2tw migrate

    You wil be prompted to enter the file path to traverse. The tool will then replace all Primeflex classes regarding the "Grid system" with TailwindCSS classes in all *.component.html files recursively. Any leading or trailing whitespace is removed from the HTML class attribute after replacement. E.g. class=" grid " will be replaced with class="flex flex-wrap -mx-2 -mt-2", class=" grid-nogutter" with class="mx-0 mt-0", etc. Prefixes like sm:, md:, lg:, xl: are preserved as well. E.g. class="sm:col-2" will be replaced with class="sm:grow-0 sm:shrink-0 sm:p-2 sm:w-2/12".