pubspec_yaml.json 5 KB
Newer Older
1 2
{
    "$schema": "http://json-schema.org/draft-04/schema#",
3
    "$comment": "This should be kept in sync with the validator in packages/flutter_tools/lib/src/flutter_manifest.dart",
4 5 6 7 8 9
    "title": "pubspec.yaml",
    "type": "object",
    "additionalProperties": true,
    "properties": {
        "name": { "type": "string" },
        "flutter": {
10 11 12 13
            "oneOf": [
                { "type": "object" },
                { "type": "null" }
            ],
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45
            "additionalProperties": false,
            "properties": {
                "uses-material-design": { "type": "boolean" },
                "assets": {
                    "type": "array",
                    "items": { "type": "string" }
                },
                "services": {
                    "type": "array",
                    "items": { "type": "string" }
                },
                "fonts": {
                    "type": "array",
                    "items": {
                        "type": "object",
                        "additionalProperties": false,
                        "properties": {
                            "family": { "type": "string" },
                            "fonts": {
                                "type": "array",
                                "items": {
                                    "type": "object",
                                    "additionalProperties": false,
                                    "properties": {
                                        "asset": { "type": "string" },
                                        "weight": { "enum": [ 100, 200, 300, 400, 500, 600, 700, 800, 900 ] },
                                        "style": { "enum": [ "normal", "italic" ] }
                                    }
                                }
                            }
                        }
                    }
46
                },
47
                "module": {
48 49 50
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
51
                        "androidX": { "type": "boolean" },
52 53
                        "androidPackage": { "type": "string" },
                        "iosBundleIdentifier": { "type": "string" }
54 55
                    }
                },
56 57 58 59
                "plugin": {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78
                        "platforms": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "android": {
                                    "type": "object",
                                    "additionalProperties": false,
                                    "properties": {
                                        "package": {"type": "string"},
                                        "pluginClass": {"type": "string"}
                                    }
                                },
                                "ios": {
                                    "type": "object",
                                    "additionalProperties": false,
                                    "properties": {
                                        "pluginClass": {"type": "string"}
                                    }
                                },
79 80 81 82
                                "linux": {
                                    "type": "object",
                                    "additionalProperties": false,
                                    "properties": {
83 84
                                        "pluginClass": {"type": "string"},
                                        "dartPluginClass": {"type": "string"}
85 86
                                    }
                                },
87 88 89 90
                                "macos": {
                                    "type": "object",
                                    "additionalProperties": false,
                                    "properties": {
91 92
                                        "pluginClass": {"type": "string"},
                                        "dartPluginClass": {"type": "string"}
93
                                    }
94 95 96 97 98
                                },
                                "windows": {
                                    "type": "object",
                                    "additionalProperties": false,
                                    "properties": {
99 100
                                        "pluginClass": {"type": "string"},
                                        "dartPluginClass": {"type": "string"}
101
                                    }
102 103 104
                                }
                            }
                        },
105
                        "androidPackage": { "type": "string" },
106
                        "iosPrefix": { "type": "string" },
107
                        "macosPrefix": { "type": "string" },
108
                        "pluginClass": { "type": "string" }
109
                    }
110 111 112 113 114
                }
            }
        }
    }
}