diff --git a/snippets/snippets.json b/snippets/snippets.json index 594eeba..099c0bb 100644 --- a/snippets/snippets.json +++ b/snippets/snippets.json @@ -26,7 +26,7 @@ " @override", " Widget build(BuildContext context) {", " return Container(", - " child: ${2:null},", + " child: ${2:null},", " );", " }", "}" @@ -80,7 +80,7 @@ "prefix": "initS", "body": [ "@override", - "void initState() { ", + "void initState() {", " super.initState();", " ${0:}", "}" @@ -91,7 +91,7 @@ "prefix": "dis", "body": [ "@override", - "void dispose() { ", + "void dispose() {", " ${0:}", " super.dispose();", "}" @@ -137,8 +137,8 @@ "ListView.builder(", " itemCount: ${1:1},", " itemBuilder: (BuildContext context, int index) {", - " return ${2:};", - " },", + " return ${2:};", + " },", ")," ], "description": "Creates a scrollable, linear array of widgets that are created on demand.Providing a non-null `itemCount` improves the ability of the [ListView] to estimate the maximum scroll extent." @@ -149,11 +149,11 @@ "ListView.separated(", " itemCount: ${1:1},", " separatorBuilder: (BuildContext context, int index) {", - " return ${2:};", - " },", + " return ${2:};", + " },", " itemBuilder: (BuildContext context, int index) {", - " return ${3:};", - " },", + " return ${3:};", + " },", ")," ], "description": "Creates a fixed-length scrollable linear array of list 'items' separated by list item 'separators'." @@ -204,7 +204,7 @@ "body": [ "CustomScrollView(", " slivers: [", - " ${0:}", + " ${0:}", " ],", ")," ], @@ -236,7 +236,7 @@ " },", ")," ], - "description": "Creates an Animated Builder. The widget specified to `child` is passed to the `builder` " + "description": "Creates an Animated Builder. The widget specified to `child` is passed to the `builder`" }, "Stateful Builder": { "prefix": "statefulBldr", @@ -367,8 +367,8 @@ "body": [ "@override", "String toString() {", - "return ${1:toString};", - " }" + " return ${1:toString};", + "}" ], "description": "Returns a string representation of this object." }, @@ -399,9 +399,9 @@ "description": "Create a MaterialApp", "body": [ "import 'package:flutter/material.dart';", - " ", + "", "void main() => runApp(MyApp());", - " ", + "", "class MyApp extends StatelessWidget {", " @override", " Widget build(BuildContext context) {", @@ -427,9 +427,9 @@ "description": "Create a CupertinoApp", "body": [ "import 'package:flutter/cupertino.dart';", - " ", + "", "void main() => runApp(MyApp());", - " ", + "", "class MyApp extends StatelessWidget {", " @override", " Widget build(BuildContext context) {", @@ -454,12 +454,12 @@ "prefix": "tweenAnimationBuilder", "body": [ "TweenAnimationBuilder(", - " duration: ${1:const Duration(),}", - " tween: ${2:Tween(),}", - " builder: (BuildContext context, ${3:dynamic} value, Widget? child) {", - " return ${4:Container();}", - " },", - " ), " + " duration: ${1:const Duration(),}", + " tween: ${2:Tween(),}", + " builder: (BuildContext context, ${3:dynamic} value, Widget? child) {", + " return ${4:Container();}", + " },", + ")," ], "description": "Widget builder that animates a property of a Widget to a target value whenever the target value changes." }, @@ -467,11 +467,11 @@ "prefix": "valueListenableBuilder", "body": [ "ValueListenableBuilder(", - " valueListenable: ${1: null},", - " builder: (BuildContext context, ${2:dynamic} value, Widget? child) {", - " return ${3: Container();}", - " },", - " )," + " valueListenable: ${1: null},", + " builder: (BuildContext context, ${2:dynamic} value, Widget? child) {", + " return ${3: Container();}", + " },", + ")," ], "description": "Given a ValueListenable and a builder which builds widgets from concrete values of T, this class will automatically register itself as a listener of the ValueListenable and call the builder with updated values when the value changes." }, @@ -479,8 +479,8 @@ "prefix": "f-test", "body": [ "test(", - " \"${1:test description}\",", - " () {},", + " \"${1:test description}\",", + " () {},", ");" ], "description": "Create a test function" @@ -489,8 +489,8 @@ "prefix": "widgetTest", "body": [ "testWidgets(", - " \"${1:test description}\",", - " (WidgetTester tester) async {},", + " \"${1:test description}\",", + " (WidgetTester tester) async {},", ");" ], "description": "Create a testWidgets function"