Skip to content

IntelliSense doesn't initialize project without @import 'tailwindcss' #1060

@manmen-mi

Description

@manmen-mi

What version of VS Code are you using?

v1.93.1

What version of Tailwind CSS IntelliSense are you using?

v0.13.41 (pre-release)

What version of Tailwind CSS are you using?

4.0.0-alpha.25

What package manager are you using?

pnpm

What operating system are you using?

macOS

Tailwind config

using '@tailwindcss/vite'

VS Code settings

settings.json
{
  "search.exclude": {
    "**/dist": true
  },
  "git.branchPrefix": "feat/",
  "npm.packageManager": "pnpm",
  "editor.unicodeHighlight.allowedCharacters": {
    "~": true
  },
  "editor.quickSuggestions": {
    "strings": "on"
  },
  "githubIssues.issueBranchTitle": "feat/issue${issueNumber}",
  "editor.linkedEditing": true,
  "editor.wordWrapColumn": 80,
  "html.format.wrapLineLength": 0,
  "editor.tabSize": 2,

  // Disable the default formatter, use eslint instead
  "editor.formatOnSave": false,
  "editor.formatOnPaste": false,

  // Auto fix
  "editor.codeActionsOnSave": {
    "source.fixAll.eslint": "explicit",
    "source.organizeImports": "never"
  },

  // Silent the stylistic rules in you IDE, but still auto fix them
  "eslint.rules.customizations": [
    { "rule": "style/*", "severity": "off", "fixable": true },
    { "rule": "format/*", "severity": "off", "fixable": true },
    { "rule": "*-indent", "severity": "off", "fixable": true },
    { "rule": "*-spacing", "severity": "off", "fixable": true },
    { "rule": "*-spaces", "severity": "off", "fixable": true },
    { "rule": "*-order", "severity": "off", "fixable": true },
    { "rule": "*-dangle", "severity": "off", "fixable": true },
    { "rule": "*-newline", "severity": "off", "fixable": true },
    { "rule": "*quotes", "severity": "off", "fixable": true },
    { "rule": "*semi", "severity": "off", "fixable": true }
  ],

  // Enable eslint for all supported languages
  "eslint.validate": [
    "javascript",
    "javascriptreact",
    "typescript",
    "typescriptreact",
    "vue",
    "html",
    "markdown",
    "json",
    "jsonc",
    "yaml",
    "toml",
    "xml",
    "gql",
    "graphql",
    "astro",
    "css",
    "less",
    "scss",
    "pcss",
    "postcss",
    "svelte"
  ]
}

Reproduction URL

https://github.com/manmen-mi/studious-octo-garbanzo

Describe your issue

IntelliSense works

@import 'tailwindcss';

IntelliSense doesnt works

@layer theme, base, components, utilities;

@import 'tailwindcss/preflight' layer(base);
@import 'tailwindcss/theme' layer(theme);
@import 'tailwindcss/utilities' layer(utilities);

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions