diff --git a/snippets/python/python.json b/snippets/python/python.json index eae0151f..3b664ceb 100644 --- a/snippets/python/python.json +++ b/snippets/python/python.json @@ -10,14 +10,24 @@ "description": "Ignore specific line diagnostic in pyright (ignore all is unsafe)" }, "Multiline string": { - "prefix": "#", + "prefix": "#s", "body": ["\"\"\"$0", "\"\"\""], - "description": "Snippet to avoid autopair plugin annoyances when typing multiple \"" + "description": "Snippet to avoid weird autopair plugin behaviour" }, "One-line multiline string": { - "prefix": "##", + "prefix": "#ss", "body": "\"\"\"$0\"\"\"", - "description": "Snippet to avoid autopair plugin annoyances when typing multiple \"" + "description": "Snippet to avoid weird autopair plugin behaviour" + }, + "Single-quote multiline string": { + "prefix": "#q", + "body": ["'''$0", "'''"], + "description": "Snippet to avoid weird autopair plugin behaviour" + }, + "One-line single-quote multiline string": { + "prefix": "#qq", + "body": "'''$0'''", + "description": "Snippet to avoid weird autopair plugin behaviour" }, "self": { "prefix": "s", @@ -140,15 +150,20 @@ "description": "Class definition template" }, "Method": { - "prefix": "defs", + "prefix": "defm", "body": ["def ${1:mname}(self$2):", "\t${3:pass}"], "description": "Class method definition" }, "Method w/ return type": { - "prefix": "defst", + "prefix": "defmt", "body": ["def ${1:mname}(self$2) -> ${3:None}:", "\t${4:pass}"], "description": "Class method definition" }, + "Init method": { + "prefix": "defi", + "body": ["def __init__(self$1):", "\t${2:pass}"], + "description": "Class method definition" + }, "property template": { "prefix": "property", "body": [