sweetyjalan7

sweetyjalan7

Lv2

Sweety Jalan

2 Followers
11 Following
0 Helped

ANSWERS

Published14

Subjects

Electrical Engineering1Computer Science6Biology1Mathematics1Chemistry5

Testing to see if this method works in formatting the flutter code using triple backticks. Hopefully this works

```

 

 

```

import 'package:flutter/material.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:todolist/pages/tasklist/tasklist.dart'; import 'package:todolist/pages/tasklistdetails/tasklistdetails.dart';
void main() {   runApp(const MyApp()); }
class MyApp extends StatelessWidget {   const MyApp({super.key});
  @override   Widget build(BuildContext context) {     return MaterialApp(         title: 'Flutter Demo',         theme: ThemeData(           primarySwatch: Colors.blue,           textTheme: GoogleFonts.robotoCondensedTextTheme(),         ),         initialRoute: '/tasklist',         routes: {           '/tasklist': ((context) =>               const TaskListPage(title:"Task List1 Page")),           '/tasklistdetails': ((context) =>               const TaskListDetailsPage(title: "Task List Details Page"))         });   } }
class MyHomePage extends StatefulWidget {   const MyHomePage({super.key, required this.title});   final String title;   @override   State<MyHomePage> createState() => _MyHomePageState(); }
class _MyHomePageState extends State<MyHomePage> {   @override   Widget build(BuildContext context) {     return Scaffold(       appBar: AppBar(         title: Text(widget.title),       ),       body: const Text('Task list page'),       floatingActionButton: Theme(         data: Theme.of(context).copyWith(splashColor: Colors.amber),         child: FloatingActionButton(           onPressed: () =>{Navigator.pop(context)},           tooltip: 'Increment',           child: const Icon(Icons.add),         ),       ), // This trailing comma makes auto-formatting nicer for build methods.     );   } } ```
Answer:You can also try using backticks (`) to enclose your code block. Simply...
Answer: you want to type in answer box I am typing for you import 'package:flu...
Answer:Cloud computing is a model for delivering on-demand access to shared co...
Answer:Magnesium has a density of 1.74 g/ml - which is pretty low for a metal,...
Answer: The station where the buses meet is located 480 km from the second sta...

Following the suggestion from sweetyjalan7 on posting my flutter code in here. Link of my original question -

Only thing I don't see code sample button </>on this website or formatting toolbar. So I just typed it in manually. Hopefully it works once I press the Continue. Only buttons I see on this website is the formula button and number list button.

</>

import 'package:flutter/material.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:todolist/pages/tasklist/tasklist.dart'; import 'package:todolist/pages/tasklistdetails/tasklistdetails.dart';
void main() {   runApp(const MyApp()); }
class MyApp extends StatelessWidget {   const MyApp({super.key});
  @override   Widget build(BuildContext context) {     return MaterialApp(         title: 'Flutter Demo',         theme: ThemeData(           primarySwatch: Colors.blue,           textTheme: GoogleFonts.robotoCondensedTextTheme(),         ),         initialRoute: '/tasklist',         routes: {           '/tasklist': ((context) =>               const TaskListPage(title:"Task List1 Page")),           '/tasklistdetails': ((context) =>               const TaskListDetailsPage(title: "Task List Details Page"))         });   } }
class MyHomePage extends StatefulWidget {   const MyHomePage({super.key, required this.title});   final String title;   @override   State<MyHomePage> createState() => _MyHomePageState(); }
class _MyHomePageState extends State<MyHomePage> {   @override   Widget build(BuildContext context) {     return Scaffold(       appBar: AppBar(         title: Text(widget.title),       ),       body: const Text('Task list page'),       floatingActionButton: Theme(         data: Theme.of(context).copyWith(splashColor: Colors.amber),         child: FloatingActionButton(           onPressed: () =>{Navigator.pop(context)},           tooltip: 'Increment',           child: const Icon(Icons.add),         ),       ), // This trailing comma makes auto-formatting nicer for build methods.     );   } } </>



Answer: Click the "Code Sample" button (</>) located in the toolbar abov...
Answer: To find the density of the salt water, we can use the formula: density...
Answer:The density of a salt solution can be greater or lesser than the densit...
Answer:The little piece of magnesium floated up to the top of the tube when it...
Answer: Python is a popular programming language that is widely used for a var...

When I paste my flutter code in here and than post it as a question the format is screwed up. Therefore it's hard to understand it. Currently when I paste it in here looks ok. But once it gets posted it becomes messy and the codes are out of alignment hard to read them.

Is there a way to format in this website so that it is easier to read them.

Same thing with the answers that I get.

 

 

import 'package:flutter/material.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:todolist/pages/tasklist/tasklist.dart'; import 'package:todolist/pages/tasklistdetails/tasklistdetails.dart';
void main() {   runApp(const MyApp()); }
class MyApp extends StatelessWidget {   const MyApp({super.key});
  @override   Widget build(BuildContext context) {     return MaterialApp(         title: 'Flutter Demo',         theme: ThemeData(           primarySwatch: Colors.blue,           textTheme: GoogleFonts.robotoCondensedTextTheme(),         ),         initialRoute: '/tasklist',         routes: {           '/tasklist': ((context) =>               const TaskListPage(title:"Task List1 Page")),           '/tasklistdetails': ((context) =>               const TaskListDetailsPage(title: "Task List Details Page"))         });   } }
class MyHomePage extends StatefulWidget {   const MyHomePage({super.key, required this.title});   final String title;   @override   State<MyHomePage> createState() => _MyHomePageState(); }
class _MyHomePageState extends State<MyHomePage> {   @override   Widget build(BuildContext context) {     return Scaffold(       appBar: AppBar(         title: Text(widget.title),       ),       body: const Text('Task list page'),       floatingActionButton: Theme(         data: Theme.of(context).copyWith(splashColor: Colors.amber),         child: FloatingActionButton(           onPressed: () =>{Navigator.pop(context)},           tooltip: 'Increment',           child: const Icon(Icons.add),         ),       ), // This trailing comma makes auto-formatting nicer for build methods.     );   } }
Answer: Yes, there is a way to format code in this website to make it easier t...
Answer: your question is not readable
Answer:True. Insulin can cause muscle fibers to increase glycogen breakdown. H...
Answer:Q1:-How many receptades can be on a branch circuit for a refrigerator?S...

Weekly leaderboard

Start filling in the gaps now
Log in