Code Monkey home page Code Monkey logo

unocss-preset-animations's Introduction

unocss-preset-animations's People

Contributors

xsjctony avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

unocss-preset-animations's Issues

core.definePreset is not a function

Hi there

Trying to work with the preset for using shadcn-vue together with unocss, but can't seem to figure what this error is related to.
When my config looks like this:

import {
  defineConfig,
  presetIcons,
  presetUno,
  transformerDirectives,
} from "unocss";

import presetAnimations from "unocss-preset-animations";
import { presetShadcn } from "unocss-preset-shadcn";

export default defineConfig({
  presets: [
    presetUno(),
    presetIcons({
      prefix: "i-",
      extraProperties: {
        display: "inline-block",
        "vertical-align": "middle",
      },
    }),
    presetShadcn({
      color: "slate",
    }),
    presetAnimations(),
  ],
  transformers: [transformerDirectives()],

I get the following error on npm run dev:

/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/unocss-preset-animations/dist/index.cjs:188
const presetAnimations = core.definePreset(() => ({
                              ^

TypeError: core.definePreset is not a function
    at /Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/unocss-preset-animations/dist/index.cjs:188:31
    at evalModule (/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/jiti/dist/jiti.js:1:256443)
    at jiti (/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/jiti/dist/jiti.js:1:254371)
    at /Users/frederikkirkeskov/Sites/hrzn-frontend/uno.config.js:11:54
    at evalModule (/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/jiti/dist/jiti.js:1:256443)
    at jiti (/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/jiti/dist/jiti.js:1:254371)
    at loadConfigFile (/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/unconfig/dist/index.cjs:162:13)
    at async Object.load (/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/unconfig/dist/index.cjs:85:24)
    at async Object.loadConfig (/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/@unocss/config/dist/index.cjs:50:18)
    at async Object.reloadConfig (/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/@unocss/vite/dist/index.cjs:108:20)
    at async FSWatcher.<anonymous> (/Users/frederikkirkeskov/Sites/hrzn-frontend/node_modules/@unocss/vite/dist/index.cjs:1052:9)

Node.js v20.11.0

I'm not using TypeScript, unfortunately, maybe this might be related.
Running [email protected], but seems like it's related to the imports in the dist/index.cjs of this package..

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.