BBASMJSEnviroment.h 852 Bytes
//
//  BBASMJSEnviroment.h
//  SWAN
//
//  Created by baidu on 2018/10/25.
//  Copyright © 2018 baidu. All rights reserved.
//

#import <Foundation/Foundation.h>

@class BBASMJSConfig;
@import JavaScriptCore;

NS_ASSUME_NONNULL_BEGIN

@protocol BBASMJSEnviromentExports <JSExport>

@property (nonatomic, copy) NSString *basePath;
@property (nonatomic, copy) NSString *userDataPath;
@property (nonatomic) BBASMJSConfig *config;
@property (nonatomic, copy) NSString *viewMode;

@end

@interface BBASMJSEnviroment : NSObject <BBASMJSEnviromentExports>

@property (nonatomic, copy) NSString *basePath;
@property (nonatomic, copy) NSString *userDataPath;
@property (nonatomic) BBASMJSConfig *config;
/// slave 渲染模式
@property (nonatomic, copy) NSString *viewMode;

- (instancetype)initWithBasePath:(NSString *)basePath;

@end

NS_ASSUME_NONNULL_END