react-native-navigation的迁移库

RNNComponentOptions.m 458B

123456789101112131415161718192021
  1. #import "RNNComponentOptions.h"
  2. @implementation RNNComponentOptions
  3. - (instancetype)initWithDict:(NSDictionary *)dict {
  4. self = [super init];
  5. self.name = [TextParser parse:dict key:@"name"];
  6. self.componentId = [TextParser parse:dict key:@"componentId"];
  7. self.alignment = [TextParser parse:dict key:@"alignment"];
  8. self.waitForRender = [BoolParser parse:dict key:@"waitForRender"];
  9. return self;
  10. }
  11. - (BOOL)hasValue {
  12. return _name.hasValue;
  13. }
  14. @end