• Stars
    star
    89
  • Rank 359,230 (Top 8 %)
  • Language
    Swift
  • License
    MIT License
  • Created about 8 years ago
  • Updated almost 6 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Enable autocomplete use resources in swift project.

ResourceKit

MIT License platform

Enable autocomplete use resources in swift project.

まだハードコードで消耗してるの? ResourceKitで安全コーディング!

How does ResourceKit work?

ResouceKit makes your code that uses write for resources:

  • Becomes clear, nessary to cast and guessing easy what a method will return.
  • Checked, the mistaken character doesn't enter your app code.
  • Autocompleted, never have to exist hard code when using resource.
Standard use resources.
// Get ViewController
let storyboard = UIStoryboard(name: "Storyboard", bundle: nil)
let viewController = storyboard.instantiateViewController(withIdentifier: "XXXX") as! ViewController

// PerformSegue
performSegue(withIdentifier: "Open", sender: sender)

// Nib
let nib = UINib(nibName: "TableViewCell", bundle: nil)
let cell = nib.instantiate(withOwner: nil, options: nil)[0] as! TableViewCell

Please see ResouceKitDemo for more information, or Examples.md

Use ResourceKit.
// Get ViewController
let viewController = ViewController.instanceFromStoryboard() // <- viewController is ViewController class.

// PerformSegue
performSegueOpen() // <- can write to use autocomplete.

// Nib
let cell = TableViewCell.Xib.view() // <- easy get instance.

Features

After installing ResourceKit into your project, and build it. ResourceKit will correct any missing/changed/added resources.

ResouceKit supports resource types.

Installation

CocoaPods is the recommended way of installation, as this avoids including any binary files into your project.

Cocoapods

  1. Add pod 'ResourceKit' to your Podfile and run pod install.
  2. In Xcode: Click on your project in the file list, choose your target under TARGETS, click the Build Phases tab and add a New Run Script Phase by clicking the little plus icon in the top left.
  3. Drag the new Run Script phase above the Compile Sources phase and below Check Pods Manifest.lock, expand it and paste the following script: "$PODS_ROOT/ResourceKit/ResourceKit"
  4. Build your project, in Finder you will now see a ResourceKit.generated.swift in the $SRCROOT-folder, drag the ResourceKit.generated.swift files into your project and uncheck Copy items if needed

Manual

  1. Download a ResourceKit , unzip it and put it your source root directory.
  2. In Xcode: Click on your project in the file list, choose your target under TARGETS, click the Build Phases tab and add a New Run Script Phase by clicking the little plus icon in the top left
  3. Drag the new Run Script phase above the Compile Sources phase, expand it and paste the following script: "$SRCROOT/ResourceKit"
  4. Build your project, in Finder you will now see a ResourceKit.generated.swift in the $SRCROOT-folder, drag the ResourceKit.generated.swift files into your project and uncheck Copy items if needed.

TODO:

  • Cocoapods support.
  • Images support.
  • LocaliazedString Support.
  • Adjust indent.
  • Collaboration SegueAddition.
  • User Chose Generate Resource Support.

Help:

Q.When want to use a Third party UI Library, how should it be done

A. You can write import CustomView to ResourceKit.generated.swift.
And build again, but It's left import CustomView!

License

ResourceKit is released under the MIT license. See LICENSE.txt for details.

More Repositories

1

SpreadsheetView

Full configurable spreadsheet view user interfaces for iOS applications. With this framework, you can easily create complex layouts like schedule, gantt chart or timetable as if you are using Excel.
HTML
3,443
star
2

Gecco

Simply highlight items for your tutorial walkthrough, written in Swift
Swift
1,884
star
3

Gedatsu

Gedatsu provide readable format about AutoLayout error console log
Swift
532
star
4

Kaeru

Switch viewcontroller like ios task manager
Swift
511
star
5

Pilll

Pilll x Flutter
Dart
290
star
6

Kuri

Automatically generates from template and imports it into Xcode project.
Swift
253
star
7

Sigma

Sigma is a Figma plugin of automatically generate SwiftUI code from Figma
TypeScript
198
star
8

Conv

Conv smart represent UICollectionView data structure more than UIKit.
Swift
157
star
9

Ocha

Listen to the file system change notifications and raises events when a directory, or file in a directory, changes. 🍵
Swift
130
star
10

UtilityType

Swift
83
star
11

XcodeProject

Xcode utility for reading and writing pbxproj file format.
Swift
60
star
12

Async

Swift
57
star
13

NotificationHub

NotificationHub is managed GitHub notification.
Swift
56
star
14

connpass-notification

Notify to slack for connpass events from participant via gmail.
TypeScript
52
star
15

StringAttribute

StringAttribute is simple to write about NSAttributedString
Swift
46
star
16

SegueAddition

Easily way to write perfromSegueWithIdentifier.
Swift
44
star
17

PersonalHistory

My programmer personal history.
39
star
18

XChanger

XChanger can exchange to behavior for URL request and response
Swift
35
star
19

Teapot

Swift
31
star
20

async_value_group

Dart
31
star
21

bannzai

\(^o^)/
30
star
22

UserDefaultsGenerator

UserDefaultsGenerator generate swift code for easily management for (NS)UserDefaults key and value type.
Swift
30
star
23

In100Days

Dart
28
star
24

CoreAnimator

Easily way to bridge UIView animation and CoreAnimation
Swift
27
star
25

itree

itree can be interactive file browse and exec any command.
Go
25
star
26

HoshiHoshii

星が欲しい!星欲しい!星が欲しい!星が欲しい!星欲しい!星が欲しい!星が欲しい!星欲しい!星が欲しい!星が欲しい!星欲しい!星が欲しい!星が欲しい!星欲しい!星が欲しい!星が欲しい!星欲しい!星が欲しい!
Swift
25
star
27

notifier

notifier connect to slack when any actions on GitHub
Go
24
star
28

Enumerable

Swift Enum can enumerable.
Swift
24
star
29

Inu

Easily way to write a control logic for call once function in instance.
Swift
23
star
30

Ragnarok

Remake of destiny.
Swift
23
star
31

Photomark

Swift
21
star
32

Posusume

Swift
19
star
33

constructor

constructor is generated Constructor for struct.
Go
18
star
34

castle

My castle. But I don't have home. I'm KOJIKI.
Shell
18
star
35

yomiage

Swift
16
star
36

SwiftLove

hogehogehogehoge
15
star
37

xcp

Xcode utility for reading and writing pbxproj file format.
Swift
15
star
38

hockam

Ruby
14
star
39

StackViewBackgroundChecker

Swift
14
star
40

switchecker

switchecker is tool of checking for missing switch case about go enum
Go
14
star
41

kiminoadanaha

TypeScript
13
star
42

tekimon

Ruby
12
star
43

hatena-blog

HTML
12
star
44

TransNotion-Swift

Swift
11
star
45

maccha-ai

TypeScript
11
star
46

EraCalculator

Last library of 平成.
Swift
10
star
47

toilet

Swift
10
star
48

MultipeerConnectiveDemo

Swift
10
star
49

repository_from_sqlboiler

repository_from_sqlboiler can be generated Repository Pattern Go source code for from sqlboiler's generated Go code.
Go
10
star
50

TabPager

Paging viewcontroller with top tab bar.
Swift
10
star
51

illust_ya_tools

Ruby
10
star
52

TransNotionBackend

9
star
53

taion

Dart
9
star
54

star-kojiki

TypeScript
9
star
55

ToiletMap

TypeScript
9
star
56

KuriDemo

Demonstration for Kuri https://github.com/bannzai/Kuri
Swift
9
star
57

Swdifft

Swdifft is string diff library of longest common subsequence.
Swift
9
star
58

CopiPen

Swift
8
star
59

commit_template

bannzai's commit template.
Shell
8
star
60

file-list

file-list is tool for output to file names below passed directory.
Go
8
star
61

SwiftTUI

TUI utility framework with Swift.
C
7
star
62

NoMotherYesTeacher

No Mother Yes Teacher.
Objective-C
7
star
63

sqlboiler_utility

7
star
64

kondate_gacha_rails

Ruby
7
star
65

psui

UI for ps.
7
star
66

mysqlboiler

Tool of generated boiler plate code from mysql schema.
Go
7
star
67

PosusumeBackend

TypeScript
7
star
68

swift_ui

I amazed SwiftUI
6
star
69

pilll_backend_dart

Dart
6
star
70

SPMDemo

Swift package manager demo
Swift
6
star
71

Gomoku

Swift
6
star
72

MyKeyboard

My keyboard made with a arduino leonardo
Arduino
6
star
73

ruby_demo_app

Ruby on Rails Demo App
Ruby
6
star
74

SwiftPry

Swift
6
star
75

Switcher

6
star
76

GraphQLBoiler

6
star
77

Yggdrasill

Yggdrasill.
6
star
78

demo-nestjs

TypeScript
6
star
79

_DigitalDetox

Swift
6
star
80

GGHS

Swift
6
star
81

homebrew-kuri

homebrew-kuri
Ruby
6
star
82

orecon-unity-ar-muscle

[俺コン](https://orecon.connpass.com/event/64285/)の発表資料
CSS
6
star
83

Eyes

Monitor file event and handling file or folder events written by swift.
Swift
6
star
84

Yamru

Easily read and write for yaml file.
6
star
85

BlockRepeatedPushTransition

Introduce blocking repeated push transition to use navigationController.pushViewController
Swift
6
star
86

Presentations

LT等で発表したやつここに置こう。ローカルでいつも見失っちゃう
6
star
87

pilll-widget-screenshot

Swift
6
star
88

NSString-Union

Objective-C
5
star
89

gqlgen-demo

Go
5
star
90

reversi

Swift
5
star
91

TechBookTableDrivenTestsSwift

5
star
92

Resumemo

TypeScript
5
star
93

first_app

Ruby on Rails tutorial
Ruby
5
star
94

UIProgressView-AnimateDuration

UIProgressView full animation category
Objective-C
5
star
95

Suift

Swift
5
star
96

SampleForMVP

Sample for most value professional
Swift
5
star
97

MusicHackDay

Swift
5
star
98

iOSDC-BlackMagick

Objective-C
5
star
99

MySwiftExtension

My swift extension
Swift
5
star
100

Kalendar

Calendar view.
Swift
5
star