Label cannot export localized string key

Hello all. This is my code snippet.

RecordListView()
                .tabItem {
                    Label("Record List", systemImage: "list.clipboard")
                }
                .tag(Tab.RecordList)

When I export localizations, there is no Record List in the .xcloc file.

Then I use LocalizedStringKey for Label and export localizations file, the code is as follows:

let RecordsString:LocalizedStringKey = "Tab.Records"
RecordListView()
                .tabItem {
                    Label(RecordsString, systemImage: "list.clipboard")
                }
                .tag(Tab.RecordList)

There is still no Tab.Records.

Hello, Please double-check the build setting: Use Compiler to Extract Swift Strings

Label cannot export localized string key
 
 
Q