Questions tagged [today-extension]

A Today Extension is a widget shown in the today view of the notification center of OS X and iOS.

Usually a today extension shows informations which is related to current events, like current sock prices, weather and upcoming events. Some extensions though provide other functionality like a calculator or iTunes controls.

Today Extensions were introduced in iOS 8.0 and OS X 10.10 and can be published by developers through the App Store.

App extensions in the Today view are called widgets. Widgets give users quick access to information that’s important right now. For example, users open the Today view to check current stock prices or weather conditions, see today’s schedule, or perform a quick task such as marking an item as done. Users tend to open the Today view frequently, and they expect the information they’re interested in to be instantly available.

To read more follow this link - App Extension programming guide

460 questions
81
votes
6 answers

Sharing UserDefaults between extensions

Creating a Today widget and I am using UserDefaults(suiteName:) to persist some data. In the main application I am using UserDefaults.standard(). This can't be read (or can it?) by the extension which is why I use the suiteName: constructor. Data…
59
votes
5 answers

Today App Extension Widget Tap To Open Containing App

I've implemented a Today widget for my application +Quotes which displays the day's quote within the notification center with the help of these Apple Docs. What I'd like to accomplish is opening the Containing App, in this case +Quotes, when the…
Daniel Storm
  • 18,301
  • 9
  • 84
  • 152
43
votes
1 answer

Flutter: Is it somehow possible to create App Widgets (Android) and Today Extensions (iOS)?

I took a look at flutter for building a mobile app. Is it possible to create Widgets (not flutter-widgets, but App Widgets (Android) and Today Extensions (iOS)) in a flutter app? I guess it can't be done with dart, but is there a way of implementing…
hendra
  • 2,531
  • 5
  • 22
  • 34
38
votes
1 answer

How to access CoreData model in today extension (iOS)

Is it possible to work with my CoreData model in the today extension in swift like in the original app? If yes, how can I create the NSManagedObjectContext? I really have no clue, beside the group-identifier, but unfortunatly I don't know how to…
Ben
  • 3,455
  • 3
  • 26
  • 31
31
votes
5 answers

Maximum height of iOS 8 Today Extension?

I am working on a Today Extension with a dynamically sized table. I have been able to get the table to resize for the content using: self.preferredContentSize = accountsTable.contentSize However, I have found that it will not get taller than a…
user2816488
  • 325
  • 3
  • 4
28
votes
5 answers

How to use Crashlytics with iOS / OS X today view extensions?

Since today extensions run as separated a process I am sure they will not log any crashes out of the box. I assume we need to initialize Crashlytics on the widget separately. E.g. in the viewDidLoad method of the TodayViewController. Is anybody…
martn_st
  • 2,576
  • 1
  • 24
  • 30
26
votes
7 answers

Today-Widget "Unable to load" error

From time to time widget crashing with "unable to load" error. Is anyone know how to fix it? Widget haven't requests to server or smth else.
Ildar.Z
  • 666
  • 1
  • 7
  • 17
23
votes
3 answers

What is the height of the new iOS 10 Today Widget/Extension?

I am building an iOS Today widget, and while testing for iOS 10 I noticed that all widgets are now being given the same height (previous versions allowed the dev to set the height). What is the ideal height/what is the best practice for dealing with…
user3658503
  • 231
  • 1
  • 2
  • 3
23
votes
2 answers

Today Widget tableView freezes

I have a today widget that contains two things: A UILabel A UITableView In my viewWillAppearI set the label to be visible and my tableView to be hidden and I set the label text to "Loading". See image below. Then I get a location and when this is…
user5700760
22
votes
9 answers

How to launch a parent iOS App from its App Extension

Does any one know how to launch the parent app from the app extension's view controller? I just want to launch the main app from its app extension.
loganathan
  • 2,056
  • 2
  • 23
  • 34
21
votes
3 answers

Today Widget Extension Height - iOS10

The height for the Today's widget view mode cannot be set for compact Mode. No matter whatever value I set. It sets the height of the widget to a default value. The expanded mode works perfect and the value is properly set and reflected in the…
Taimur Ajmal
  • 2,778
  • 6
  • 39
  • 57
20
votes
2 answers

Perform action in host app from Today extension(Widget) Without opening app ios

I want to manage some action in containing app from today extension(Widget). Full description: in my containing app, some action (like play/pause audio) perform. And want to manage that action also from today extension(widget). An action continues…
20
votes
1 answer

iOS Swift Today Extension: import class from container app?

I have an app with a Today widget. I would like to use a model class from the container app in the TodayViewController.swift. Is such a thing possible? I copied the file into the Today Extension folder and tried to import it. No dice. I can't find…
MayNotBe
  • 2,110
  • 3
  • 32
  • 47
19
votes
3 answers

How to determine the Today extension left margin properly in iOS 8?

I'm trying to find out how to calculate the left margin in the Today extension main view to align the contents to the rest of the Today view labels. Here's an example with a clean Xcode project using a Today extensions (I've added color to the view…
Markus Rautopuro
  • 7,997
  • 6
  • 47
  • 60
16
votes
1 answer

iOS in-app-purchase + Today Extension widget

So I have an app which requires a subscription (via an IAP), and it provides a Today Widget. Within the widget (as well as within the app) I use RMStore to check the App Receipt in the bundle for an active subscription. It works fine in the…
DanM
  • 7,037
  • 11
  • 51
  • 86
1
2 3
30 31