I want to add a cookie to IOS webView application with swift 4.2 in XCode but it does not work. Below is one of the code examples I tried to apply and it does not work. Can anyone help me?
let cookieProps:[HTTPCookiePropertyKey:Any]=[
HTTPCookiePropertyKey.domain:"https://system.fast-apps.com",
HTTPCookiePropertyKey.path:"/",
HTTPCookiePropertyKey.name:"isNative",
HTTPCookiePropertyKey.value:"IwBhE4g"]
if let cookie = HTTPCookie(properties: cookieProps){
HTTPCookieStorage.shared.setCookie(cookie)
}