【发布时间】:2021-08-03 15:15:19
【问题描述】:
文件内声明的常量值:
import 'package:flutter/material.dart';
import 'package:flutter_complete_guide/models/category.dart';
import 'package:flutter_complete_guide/models/meal.dart';
const kDummyMeals = <Meal>[
Meal(
id: 'm1',
categories: [
'c1',
'c2',
],
title: 'Spaghetti with Tomato Sauce',
affordability: Affordability.Affordable,
complexity: Complexity.Simple,
imageUrl:
'https://upload.wikimedia.org/wikipedia/commons/thumb/2/20/Spaghetti_Bolognese_mit_Parmesan_oder_Grana_Padano.jpg/800px-Spaghetti_Bolognese_mit_Parmesan_oder_Grana_Padano.jpg',
duration: 20,
ingredients: [
'4 Tomatoes',
'1 Tablespoon of Olive Oil',
'1 Onion',
'250g Spaghetti',
'Spices',
'Cheese (optional)'
],
steps: [
'Cut the tomatoes and the onion into small pieces.',
'Boil some water - add salt to it once it boils.',
'Put the spaghetti into the boiling water - they should be done in about 10 to 12 minutes.',
'In the meantime, heaten up some olive oil and add the cut onion.',
'After 2 minutes, add the tomato pieces, salt, pepper and your other spices.',
'The sauce will be done once the spaghetti are.',
'Feel free to add some cheese on top of the finished dish.'
],
isGlutenFree: false,
isVegan: true,
isVegetarian: true,
isLactoseFree: true,
),
// some other values
]
错误: URI 的目标不存在:'package:flutter_complete_guide/dummy_categories.dart'。 (文档)尝试创建由 URI 引用的文件,或尝试为确实存在的文件使用 URI。
结构:
扑医生 医生摘要(要查看所有详细信息,请运行 flutter doctor -v):
[✓] Flutter (Channel stable, 2.0.6, on Linux, locale uk_UA.UTF-8)
[✓] Android 工具链 - 为 Android 设备开发(Android SDK 版本 30.0.3)
[✓] Chrome - 为网络开发
[✓] Linux 工具链 - 为 Linux 桌面开发
[✓] Android Studio [✓] 已连接设备(2 个可用)
• 未发现任何问题!
Android Studio 4.2
【问题讨论】:
标签: flutter android-studio ubuntu