Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

jessa-vue-components

Package Overview
Dependencies
Maintainers
1
Versions
203
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jessa-vue-components

  • 5.3.1563
  • unpublished
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

Lorem Ipsum

Lorem Ipsum is a simple lorem ipsum generator for iOS, watchOS, tvOS, and macOS apps. It supports generating text in different formats (words, sentences, paragraphs), miscelianous data (names, URLs, dates etc.) and placeholder images.

This project was inspired by a great static site generator Middleman. Its lorem ipsum feature was also a data source for this project.

Table of Contents

Installation

CocoaPods

Lorem Ipsum can be integrated into your Xcode project using CocoaPods by putting following line into your Podfile and running pod install:

pod 'LoremIpsum', '~> 1.0'

Swift Package Manager

Lorem Ipsum can be added as a Swift Package by including it in your Package.swift file.

Manual

Alternatively you can copy the files LoremIpsum.h and LoremIpsum.m to your project.

Usage

Lorem Ipsum is usable in both Objective-C and Swift.

Objective-C

Wherever you want to use Lorem Ipsum functionality, import the header file.

#import "LoremIpsum.h"
Texts
NSString *word = LoremIpsum.word; // => "voluptatem"
NSString *words = [LoremIpsum wordsWithNumber:5]; // => "est dolores voluptatem cumque itaque"
NSString *sentence = LoremIpsum.sentence; // => "Facilis magni autem ut iure cum voluptas excepturi eos."
NSString *sentences = [LoremIpsum sentencesWithNumber:2];
NSString *paragraph = LoremIpsum.paragraph;
NSString *paragraphs = [LoremIpsum paragraphsWithNumber:2];
NSString *title = LoremIpsum.title; // => "Et Quibusdam"
Misc. Data
NSString *firstName = LoremIpsum.firstName; // => "Dora"
NSString *lastName = LoremIpsum.lastName; // => "Glass"
NSString *name = LoremIpsum.name; // => "Tomas Beasley"
NSString *email = LoremIpsum.email; // => "jared.finch@hotmail.com"
NSURL *URL = LoremIpsum.URL; // => "http://stumbleupon.com/"
NSString *tweet = LoremIpsum.tweet;
NSDate *date = LoremIpsum.date;

Swift

Wherever you want to use Lorem Ipsum functionality, import the module.

import LoremIpsum
Texts
let word: String = LoremIpsum.word // => "voluptatem"
let words: String = LoremIpsum.words(withNumber: 5) // => "est dolores voluptatem cumque itaque"
let sentence: String = LoremIpsum.sentence  // => "Facilis magni autem ut iure cum voluptas excepturi eos."
let sentences = LoremIpsum.sentences(withNumber: 2)
let paragraph = LoremIpsum.paragraph
let paragraphs = LoremIpsum.paragraphs(withNumber: 2)
let title = LoremIpsum.title // => "Et Quibusdam"
Misc. Data
let firstName = LoremIpsum.firstName // => "Dora"
let lastName = LoremIpsum.lastName // => "Glass"
let name = LoremIpsum.name // => "Tomas Beasley"
let email = LoremIpsum.email // => "jared.finch@hotmail.com"
let url: URL = LoremIpsum.URL // => "http://stumbleupon.com/"
let tweet: String = LoremIpsum.tweet
let date = LoremIpsum.date

Images

Lorem Ipsum supports creating placeholder images by downloading them from following supported services:

ServiceValue of LIPlaceholderImageService
lorempixel.comLIPlaceholderImageServiceLoremPixel
dummyimage.comLIPlaceholderImageServiceDummyImage
placekitten.comLIPlaceholderImageServicePlaceKitten

Lorem Ipsum offers methods for synchronous and asynchronous downloading of images as well as retrieving the URL for an image without downloading it. All methods work for all four supported platforms. According to the platform, UIImage or NSImage instances are created.

Synchronous Downloading
UIImage *image = [LoremIpsum placeholderImageFromService:LIPlaceholderImageServicePlaceKitten
                                                withSize:CGSizeMake(250, 250)];
                                                 
NSImage *image = [LoremIpsum placeholderImageWithSize:NSMakeSize(100, 400)];
Asynchronous Downloading
[LoremIpsum asyncPlaceholderImageFromService:LIPlaceholderImageServicePlaceKitten
                                    withSize:CGSizeMake(250, 250)
                                  completion:^(UIImage *image) {
                                      // use image here
                                  }];
                                  
[LoremIpsum asyncPlaceholderImageWithSize:NSMakeSize(100, 400)
                               completion:^(NSImage *image) {
                                   // use image here
                               }];
Image URLs
NSURL *URL = [LoremIpsum URLForPlaceholderImageFromService:LIPlaceholderImageServiceDummyImage
                                                  withSize:CGSizeMake(250, 250)];

Example Projects

This repository contains four example projects for iOS, watchOS, tvOS, and macOS where the usage of Lorem Ipsum is shown.

Author

Lukas Kubanek // lukaskubanek.com // @kubanekl

License

Usage is provided under the MIT License. See LICENSE.md for the full details.

FAQs

Package last updated on 03 Nov 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc