4

Using PHPStorm 3.0:

Is there a way to tame auto-completion in css files? I've disabled everything in "Preferences > Editor > Code Completion", yet I still observe the following behavior:

Say I'd try to type

.list {

}

When typeing ".list" and pressing the space key to add a { bracket, PHPStorm automatically expands .list to

.list-style-type:

; 

This happens with almost every other word that also occurs as a css property even in comments Any ideas on how to stop this without altering PHP/JS auto complete behavior?

2 Answers 2

7

It seems you set Space shortcut for live template expanding (Settings | Live templates). If so, this behaviour is by design.

Sign up to request clarification or add additional context in comments.

1 Comment

Better check below answer, because if you disable live templates you can't use them. Just disabling insert selected variant by typing dot, space, ect. is much better as you can still use completion by hitting tab or enter.
3

Go to Editor > General > Code Completion.
Uncheck Insert selected variant by typing dot, space, ect.

After doing this, your example of .list { will no longer insert .list-style-type: when pressing space before the {.

1 Comment

That saved me a lot of pain, not only with auto-completion in CSS scope, but also in SQL and other scopes.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.