Skip to content
| Marketplace
Sign in
Visual Studio Code>Snippets>SWAN SNIPPETSNew to Visual Studio Code? Get it now.
SWAN SNIPPETS

SWAN SNIPPETS

shanli

|
332 installs
| (0) | Free
Code snippets for Swan
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Swan Snippets

Code snippets for Swan in order to let you develop faster.

为以下开发提供代码片段自补全功能:

  • AtomEngine

Features

  • 提供smarty、php预处理文件Ala全部API的自动补全功能
  • 提供变量、模块等代码智能提示
  • 提供触发Atom组件补全后自动添加组件引用

Snippets available

Swan

提供开发模板

prefix:

  • stemplate
    • 开发模板: template/script/style标签组
  • sconfig
  • sscript
  • sstyle
  • sstyle-less

Swan

atom/prefix:

  • stemplate
    • {{ }} 文本插值
  • component
  • template
  • ......

config

支持目前所有atom组件引用

prefix:

  • s-button
  • s-dialog
  • s-picture
  • ......

Plans

Common Issues

配置修改setting.json用户设置

  • atom中无法使用vscode内置插件emmet语法

    修改emmet语言映射

    "emmet.includeLanguages": {
        "atom-html": "html",
        "atom": "html"
    }
    
  • nextpage 代码自补全功能不生效

    配置语言文件关联

    "files.associations": {
        "*.atom.html": "atom"
    }
    
  • vscode自带单词提示优先级高于sinppets

    设置取消文本提示, 或将snippets优先级设置最高

    "editor.wordBasedSuggestions": false,
    "editor.snippetSuggestions": "top"  // 该行配置不建议使用
    
  • 双击组件无法选中组件整体

    设置编辑器单词导航分隔符

    "editor.wordSeparators": "`~!@#$%^&*()-=+[{]}\\|;:'\",.<>/?"
    
  • 字符串内无法使用自动补全功能

    设置编辑器键入

    "editor.quickSuggestions": {
        "other": true,
        "comments": false,
        "strings": true
    }
    
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft