Sha256: 0c861a11397bc5e14e0ef36dd7cb13088fca3ebb2f0b442de8c4432552015738

Contents?: true

Size: 1.74 KB

Versions: 6

Compression:

Stored size: 1.74 KB

Contents

declare module 'shakapacker' {
  import { Configuration } from 'webpack'

  export interface Config {
    source_path: string
    source_entry_path: string
    nested_entries: boolean
    css_extract_ignore_order_warnings: boolean
    public_root_path: string
    public_output_path: string
    cache_path: string
    webpack_compile_output: boolean
    shakapacker_precompile: boolean
    additional_paths: string[]
    cache_manifest: boolean
    webpack_loader: string
    ensure_consistent_versioning: boolean
    compiler_strategy: string
    useContentHash: boolean
    compile: boolean,
    outputPath: string
    publicPath: string
    publicPathWithoutCDN: string
    manifestPath: string
  }

  export interface Env {
    railsEnv: string
    nodeEnv: string
    isProduction: boolean
    isDevelopment: boolean
    runningWebpackDevServer: boolean
  }

  export const config: Config
  export const devServer: Record<string, unknown>
  export function generateWebpackConfig(extraConfig?: Configuration): Configuration
  export const globalMutableWebpackConfig: Configuration
  export const baseConfig: Configuration
  export const env: Env
  export const rules: Record<string, unknown>
  export function moduleExists(packageName: string): boolean
  export function canProcess<T = unknown>(rule: string, fn: (modulePath: string) => T): T | null
  export const inliningCss: boolean
  export * from 'webpack-merge'
}

declare module 'shakapacker/package/babel/preset.js' {
  import { ConfigAPI, PluginItem, TransformOptions } from '@babel/core'

  interface RequiredTransformOptions {
    plugins: PluginItem[]
    presets: PluginItem[]
  }

  const defaultConfigFunc: (
    api: ConfigAPI
  ) => TransformOptions & RequiredTransformOptions

  export = defaultConfigFunc
}

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
shakapacker-7.2.3 package/index.d.ts
shakapacker-7.2.2 package/index.d.ts
shakapacker-7.2.1 package/index.d.ts
shakapacker-7.2.0 package/index.d.ts
shakapacker-7.2.0.rc.0 package/index.d.ts
shakapacker-7.1.0 package/index.d.ts