Skip to Content
Mika Scraper 1.1.1 is released ๐ŸŽ‰
๐Ÿฉ MIKA TYPE ALIASType Alias: GhibliStyle

Type Alias: GhibliStyle

GhibliStyle = "Spirited Away" | "Howl's Castle" | "Princess Mononoke" | "Totoro"

Defined in: src/ghibli/ghibli.ts:8

Overview

The GhibliStyle type alias represents the available art styles associated with Studio Ghibli films. It is a union type that allows for a limited set of string literals that correspond to well-known movies.

Usage

The GhibliStyle type can be used to enforce strict type checking in functions or components that require a specific style from the Studio Ghibli collection. This ensures that only the predefined styles can be utilized, preventing potential errors based on typos or unsupported styles.

Example

const selectGhibliStyle = (style: GhibliStyle): void => { console.log(`Selected style: ${style}`); }; selectGhibliStyle("Totoro"); // Valid selectGhibliStyle("Inception"); // Error: Argument of type '"Inception"' is not assignable to parameter of type 'GhibliStyle'.

Parameters

  • style: A value of type GhibliStyle, which must be one of the following:
    • "Spirited Away"
    • "Howl's Castle"
    • "Princess Mononoke"
    • "Totoro"

Returns

This function does not return a value; it simply logs the selected style to the console.

Diagram: Mika Scraper

Last updated on