Download the PHP package aerni/apple-news without Composer

On this page you can find all versions of the php package aerni/apple-news. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package apple-news

Statamic Packagist version Packagist Total Downloads

Apple News

This Statamic addon provides a powerful integration with Apple News, making it possible to publish your collection entries to iPhone, iPad, and Mac users around the world.

Prerequisites

You first need to apply for News Publisher and create a channel before you can start publishing your content. Note that new channels have to go through an approval process before you can use them.

Next, you need to get your channel's ID and API Credentials. You can get those in News Publisher Settings -> Connect CMS -> API Key.

Installation

Install the addon using Composer:

Publish the config of the package:

The following config will be published to config/apple-news.php:

Configuration

Apple News API

Add your Apple News API credentials to your .env file:

Site

Add the handle of the site you want to use to publish on Apple News:

Collections

Add the handles of the collections whose entries you want to publish on Apple News:

Templates

Add your article template classes:

Article Templates

Creating a template

Create your first article template:

This will publish a new template to app/AppleNews/{name}.php.

Customizing a template

Each template consists of a set of methods to configure your articles. They are powered by the excellent AppleNewsAPI library that lets you define your article's layout, components, styles, etc. Make sure to take a look at the source to get an idea of the classes and methods available to you.

Previewing an article

News Preview is an app provided by Apple that lets you preview your articles in the News app. This is super useful when building out your templates.

Use the following command and provide the id of the Statamic entry you want to use for preview:

This creates an article.json file of the entry in storage/statamic/addons/apple-news/preview/.

Open the News Preview app, select the article.json file, and choose the device you want to use to preview your article.

Publishing Workflow

Publishing

Open the entry in the Statamic Control Panel that you want to publish on Apple News. Navigate to the Apple News tab and customize the options to your liking. Once you're ready to publish, flick the Published toggle and save the entry. The article is now being processed by Apple News. Refresh the page to see the current Publish State.

Updating

The article will be updated every time you save the Statamic entry.

Note: The article is updated every time the Statamic\Events\EntrySaving event is dispatched.

Unpublishing / Deleting

Unflick the Published toggle to delete the article from Apple News. Deleting the Statamic entry will do the same.

Note: Apple News doesn't support unpublishing an article. Articles can only be deleted. Alternatively you can use the Hidden toggle to hide the article from Apple News feeds.

License

Apple News is commercial software but has an open-source codebase. If you want to use it in production, you'll need to buy a license from the Statamic Marketplace.

Apple News is NOT free software.

Credits

Developed by Michael Aerni

Special Thanks

Many thanks to Duo Security and Cisco for sponsoring this addon.


All versions of apple-news with dependencies

PHP Build Version
Package Version
Requires php Version ^7.4 | ^8.0
chapter-three/apple-news-api Version ^0.3.11
spatie/laravel-ray Version ^1.24
statamic/cms Version ^3.1
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package aerni/apple-news contains the following files

Loading the files please wait ....