Coder Social home page Coder Social logo

mobile-forks / dezinezync.tistoreview Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dezinezync/tistoreview

0.0 2.0 0.0 972 KB

Show apps in the App Store from within your App (app-ception?)

License: MIT License

Objective-C 32.35% Python 61.02% JavaScript 6.63%

dezinezync.tistoreview's Introduction

TiStoreView

TiStoreView enables you to show your app or any other app, who's App ID you know, from within your app.

screenshot

TEST HARNESS EXAMPLE FOR YOUR MODULE

The example directory contains a skeleton application test harness that can be used that shows how to use the app.

The appID is obtained from iTunes Connect (for your own apps), or can be looked up by the itunes search & lookup APIs.

INSTALL YOUR MODULE

  1. Run build.py which creates your distribution
  2. cd to /Library/Application Support/Titanium
  3. copy this zip file into the folder of your Titanium SDK

REGISTER YOUR MODULE

Register your module with your application by editing tiapp.xml and adding your module. Example:

<modules>
    <module version="1.1.0">com.dezinezync.storeview</module>
</modules>

When you run your project, the compiler will know automatically compile in your module dependencies and copy appropriate image assets into the application.

USING YOUR MODULE IN CODE

To use your module in code, you will need to require it.

Example

var TiStoreView = require('com.dezinezync.storeview');
TiStoreView.showProductDialog({
    'id': '**********', // SKStoreProductParameterITunesItemIdentifier
    'ct': '', // SKStoreProductParameterCampaignToken
    'pt': '', // SKStoreProductParameterProviderToken
    'at':'', // SKStoreProductParameterAffiliateToken
    'advp': '' // SKStoreProductParameterAdvertisingPartnerToken
});

Events

// Notifies when data is being loaded over the network
TiStoreView.addEventListener('loading', callback)
	
// Notifies when the modal is ready to be shown
TiStoreView.addEventListener('willshow', callback)
	
// Notifies when the modal is ready to be dismissed (user action: Cancel button or such)
TiStoreView.addEventListener('willdismiss', callback)
	
// Notifies when an error has occurred.
TiStoreView.addEventListener('error', callback)

The example app uses Yelp's app ID for proof-of-concept purposes.

LICENSE

Please refer to the LICENSE file included with this project for the License details.

DISCLAIMER

I am in no way associated with, currently or previously have been engaged with Yelp or any of their partners, employees, etc. I've used Yelp's app's ID just to show how the module works.

Cheers!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.