我需要包括我使用过的所有第三方库的列表,并考虑将所有许可证粘贴到一个字符串中,但我不能让一个字符串跨越多行。
String licences = 'asfasdf
asdf';上面的示例显示了一个错误:期望找到';'.dart(expected_token)未终止的字符串literal.dart(unterminated_string_literal)
我如何才能做到这一点,这样我就可以将所有的许可证粘贴到一个字符串中?
发布于 2020-04-28 10:00:35
您可以对多行使用三重引号
String licences = '''asfasdf
asdf''';https://api.dart.dev/stable/2.8.0/dart-core/String-class.html
https://stackoverflow.com/questions/61471157
复制相似问题