@types/postcss-preset-env

  • Version 7.7.0
  • Published
  • 9.73 kB
  • 2 dependencies
  • MIT license

Install

npm i @types/postcss-preset-env
yarn add @types/postcss-preset-env
pnpm add @types/postcss-preset-env

Overview

TypeScript definitions for postcss-preset-env

Index

Variables

variable postcssPresetEnv

const postcssPresetEnv: PostCSSPlugin<postcssPresetEnv.pluginOptions>;

    Interfaces

    interface pluginOptions

    interface pluginOptions {}

      property autoprefixer

      autoprefixer?: boolean | AutoprefixerOptions | undefined;
      • PostCSS Preset Env includes [autoprefixer](https://github.com/postcss/autoprefixer) and browsers option will be passed to it automatically.

        Specifying the autoprefixer option enables passing [additional options](https://github.com/postcss/autoprefixer#options) into autoprefixer.

        Passing autoprefixer: false disables autoprefixer.

      property browsers

      browsers?: string | string[] | undefined;
      • The browsers option determines which polyfills are required based upon the browsers you are supporting.

        PostCSS Preset Env supports any standard browserslist configuration, which can be a .browserslistrc file, a browserslist key in package.json, or browserslist environment variables.

        The browsers option should only be used when a standard browserslist configuration is not available.

        default

      property exportTo

      exportTo?: string | any[] | undefined;
      • The exportTo option specifies destinations where variables like Custom Media, Custom Properties, Custom Selectors, and Environment Variables can be exported to, which might be CSS, JS, and JSON files, functions, and directly passed objects.

      property features

      features?: pluginOptions.features | undefined;
      • The features option enables or disables specific polyfills by ID. Passing true to a specific feature ID will enable its polyfill, while passing false will disable it.

        Passing an object to a specific feature ID will both enable and configure it.

        Any polyfills not explicitly enabled or disabled through features are determined by the stage option.

      property importFrom

      importFrom?: string | any[] | undefined;
      • The importFrom option specifies sources where variables like Custom Media, Custom Properties, Custom Selectors, and Environment Variables can be imported from, which might be CSS, JS, and JSON files, functions, and directly passed objects.

      property insertAfter

      insertAfter?: object | undefined;
      • The insertAfter keys allow you to insert other PostCSS plugins into the chain. This is only useful if you are also using sugary PostCSS plugins that must execute before or after certain polyfills. insertAfter support chaining one or multiple plugins.

      property insertBefore

      insertBefore?: object | undefined;
      • The insertBefore keys allow you to insert other PostCSS plugins into the chain. This is only useful if you are also using sugary PostCSS plugins that must execute before or after certain polyfills. insertBefore support chaining one or multiple plugins.

      property preserve

      preserve?: boolean | undefined;
      • The preserve option determines whether all plugins should receive a preserve option, which may preserve or remove otherwise-polyfilled CSS. By default, this option is not configured.

      property stage

      stage?: number | undefined;
      • The stage option determines which CSS features to polyfill, based upon their stability in the process of becoming implemented web standards.

        postcssPresetEnv({ stage: 0 })

        The stage can be 0 (experimental) through 4 (stable), or false. Setting stage to false will disable every polyfill. Doing this would only be useful if you intended to exclusively use the features option.

        Without any configuration options, PostCSS Preset Env enables **Stage 2** features.

      Type Aliases

      type PostcssPresetEnv

      type PostcssPresetEnv = PostCSSPlugin<pluginOptions>;

        Namespaces

        namespace pluginOptions

        namespace pluginOptions {}

          interface features

          interface features {}

            property 'all-property'

            'all-property'?: boolean | object | undefined;
              'any-link-pseudo-class'?: boolean | object | undefined;

                property 'blank-pseudo-class'

                'blank-pseudo-class'?: boolean | object | undefined;

                  property 'break-properties'

                  'break-properties'?: boolean | object | undefined;

                    property 'case-insensitive-attributes'

                    'case-insensitive-attributes'?: boolean | object | undefined;

                      property 'color-functional-notation'

                      'color-functional-notation'?: boolean | object | undefined;

                        property 'color-mod-function'

                        'color-mod-function'?: boolean | object | undefined;

                          property 'custom-media-queries'

                          'custom-media-queries'?: boolean | object | undefined;

                            property 'custom-properties'

                            'custom-properties'?: boolean | object | undefined;

                              property 'custom-selectors'

                              'custom-selectors'?: boolean | object | undefined;

                                property 'dir-pseudo-class'

                                'dir-pseudo-class'?: boolean | object | undefined;

                                  property 'double-position-gradients'

                                  'double-position-gradients'?: boolean | object | undefined;

                                    property 'environment-variables'

                                    'environment-variables'?: boolean | object | undefined;

                                      property 'focus-visible-pseudo-class'

                                      'focus-visible-pseudo-class'?: boolean | object | undefined;

                                        property 'focus-within-pseudo-class'

                                        'focus-within-pseudo-class'?: boolean | object | undefined;

                                          property 'font-variant-property'

                                          'font-variant-property'?: boolean | object | undefined;

                                            property 'gap-properties'

                                            'gap-properties'?: boolean | object | undefined;

                                              property 'gray-function'

                                              'gray-function'?: boolean | object | undefined;

                                                property 'has-pseudo-class'

                                                'has-pseudo-class'?: boolean | object | undefined;

                                                  property 'hexadecimal-alpha-notation'

                                                  'hexadecimal-alpha-notation'?: boolean | object | undefined;

                                                    property 'image-set-function'

                                                    'image-set-function'?: boolean | object | undefined;

                                                      property 'lab-function'

                                                      'lab-function'?: boolean | object | undefined;

                                                        property 'logical-properties-and-values'

                                                        'logical-properties-and-values'?: boolean | object | undefined;

                                                          property 'matches-pseudo-class'

                                                          'matches-pseudo-class'?: boolean | object | undefined;

                                                            property 'media-query-ranges'

                                                            'media-query-ranges'?: boolean | object | undefined;

                                                              property 'nesting-rules'

                                                              'nesting-rules'?: boolean | object | undefined;

                                                                property 'not-pseudo-class'

                                                                'not-pseudo-class'?: boolean | object | undefined;

                                                                  property 'overflow-property'

                                                                  'overflow-property'?: boolean | object | undefined;

                                                                    property 'overflow-wrap-property'

                                                                    'overflow-wrap-property'?: boolean | object | undefined;

                                                                      property 'place-properties'

                                                                      'place-properties'?: boolean | object | undefined;

                                                                        property 'prefers-color-scheme-query'

                                                                        'prefers-color-scheme-query'?: boolean | object | undefined;

                                                                          property 'rebeccapurple-color'

                                                                          'rebeccapurple-color'?: boolean | object | undefined;

                                                                            property 'system-ui-font-family'

                                                                            'system-ui-font-family'?: boolean | object | undefined;

                                                                              Package Files (1)

                                                                              Dependencies (2)

                                                                              Dev Dependencies (0)

                                                                              No dev dependencies.

                                                                              Peer Dependencies (0)

                                                                              No peer dependencies.

                                                                              Badge

                                                                              To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                                                              You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@types/postcss-preset-env.

                                                                              • Markdown
                                                                                [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@types/postcss-preset-env)
                                                                              • HTML
                                                                                <a href="https://www.jsdocs.io/package/@types/postcss-preset-env"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>