Skip to content
A simple way to define and render UI specs on top of your iOS UI inspired by the Android library dspec from Lucas Rocha.
Objective-C
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
dspec-master
dspec.xcodeproj
dspecTests
images
.gitignore
LICENSE
README.md

README.md

dspec-iOS

A simple way to define and render UI specs on top of your iOS UI inspired by the Android library dspec from Lucas Rocha. https://github.com/lucasr/dspec

sample1

There two way to add dspec :

DesignSpecView *designView;

- (void)viewWillAppear:(BOOL)animated {
	[super viewWillAppear:animated];
	DesignSpecView *designView = [[DesignSpecView alloc] 	initWithFrame:self.view.frame];
	[[[[UIApplication sharedApplication] windows] objectAtIndex:0] addSubview:designView];
    [designView.designSpec loadSpecFromFileName:@"main_activity_spec"];
}

- (void)viewWillDisappear:(BOOL)animated {
	[designView removeFromSuperview];
}

Or you can simply add a UIView in your controller above everything.

sample2

NOTE In storyBoard, don't forget to set the background clearColor if you want a beautiful live preview of the baseline grid.

sample3

You can’t perform that action at this time.