This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Used to detect specific issue with JSON decoding | |
func decodeOrReport(data: Data) { | |
do { | |
let _ = try JSONDecoder().decode(WidgetResponse.self, from: data) | |
print("\n\n👍ALL GOOD\n\n") | |
} catch DecodingError.keyNotFound( let key, let context) { | |
print("\n\n⛔️FAILED TO DECODE\n\n") | |
print("could not find key \(key) in JSON: \(context.debugDescription)") | |
} catch DecodingError.valueNotFound( let type, let context) { | |
print("\n\n⛔️FAILED TO DECODE\n\n") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
extension String { | |
/// Returns a percent-escaped string following RFC 3986 for a query string key or value. | |
/// | |
/// RFC 3986 states that the following characters are "reserved" characters. | |
/// | |
/// - General Delimiters: ":", "#", "[", "]", "@", "?", "/" | |
/// - Sub-Delimiters: "!", "$", "&", "'", "(", ")", "*", "+", ",", ";", "=" | |
/// |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Hva dagens unge lærer fra eldre? Bør de unge lære av eldre? | |
2. Hva synes du om å følge med på nyhetene gjennom døgnet? Bør nyheter være tilgjengelig 24/7? | |
3. Hva synes du om å spise sunn mat? | |
4. Gjør sosiale medier oss mindre sosial? | |
5. Bør barna bruke mobiltelefonen i skolen? | |
6. Nordmenn tar ikke kontakt med innvandrere? | |
7. Synes du unge mennesker har **for** høye forventninger til livet og seg selv? | |
8. Hva synes du er en dårlig og god skole? | |
9. Hva må være gratis i Norge? (Kollektivtransport, utdanning?) | |
10. Er bolig og gode boligforhold viktig **for** å ha et godt liv? |
OlderNewer