• This repository has been archived on 29/Apr/2024
  • Stars
    star
    1,590
  • Rank 28,378 (Top 0.6 %)
  • Language
    C#
  • License
    Other
  • Created over 14 years ago
  • Updated 5 months ago

Reviews

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

Repository Details

Xamarin.iOS sample apps

iOS/tvOS/watchOS Samples

The samples in this directory use the Xamarin.iOS toolchain and Xamarin project files to illustrate the basics of how to work with iOS and the SDK. Visit the iOS Sample Gallery to download individual samples.

License

See the repo's license file and any additional license information attached to each sample.

Samples Layout

Version Specific Samples

Starting with iOS 8, we started adding samples that showcase specific features introduced in a release into a directory for the release. So all the new iOS 8 feature samples live in the ios8 directory, the iOS 9 features live in the ios9 directory and the iOS 10 feature lives in the ios10 directory, and so on for ios11, ios12, ios13...

watchOS

watchOS samples are in the watchOS directory, including:

NOTE: The WatchKit samples are deprecated, please refer to these samples in the watchOS directory.

tvOS

tvOS samples are in the tvos directory, including the tvOS UI Catalog.

Contributing

Before adding a sample to the repository, please run either install-hook.bat or install-hook.sh depending on whether you're on Windows or a Posix system. This will install a Git hook that runs the Xamarin code sample validator before a commit, to ensure that all samples are good to go.

Samples Submission Guidelines

Galleries

We love samples! Application samples show off our platform and provide a great way for people to learn our stuff. And we even promote them as a first-class feature of the docs site. You can find the sample galleries here:

Sample GitHub Repositories

These sample galleries are populated by samples in these GitHub repos:

The mobile-samples repository is for samples that are cross-platform. The mac-ios-samples repository is for samples that are Mac/iOS only.

Sample Requirements

We welcome sample submissions, please start by creating an issue with your proposal.

Because the sample galleries are powered by the github sample repos, each sample needs to have the following things:

  • Screenshots - a folder called Screenshots that has at least one screen shot of the sample on each platform (preferably a screen shot for every page or every major piece of functionality). For an example of this, see ios11/MapKitSample.

  • Readme - a README.md file that explains the sample, and contains metadata to help customers find it. For an example of this, see ios11/MapKitSample. The README file should begin with a YAML header (delimited by ---) with the following keys/values:

    • name - must begin with Xamarin.iOS -

      • description - brief description of the sample (< 150 chars) that appears in the sample code browser search

      • page_type - must be the string sample.

      • languages - coding language/s used in the sample, such as: csharp, fsharp, vb, objc

      • products: should be xamarin for every sample in this repo

      • urlFragment: although this can be auto-generated, please supply an all-lowercase value that represents the sample's path in this repo, except directory separators are replaced with dashes (-) and no other punctuation.

      Here is a working example from ios11/MapKitSample README raw view.

      ---
      name: Xamarin.iOS - MapKit Sample
      description: "Demo of new iOS 11 features in MapKit, grouping and splitting markers based on zoom-level. Tandm is a fictional bike sharing... (iOS11)"
      page_type: sample
      languages:
      - csharp
      products:
      - xamarin
      urlFragment: ios11-mapkitsample
      ---
      # Heading 1
      
      rest of README goes here, including screenshot images and requirements/instructions to get it running

      NOTE: This must be valid YAML, so some characters in the name or description will require the entire string to be surrounded by " or ' quotes.

  • Buildable solution and .csproj file - the project must build and have the appropriate project scaffolding (solution + .csproj files).

This approach ensures that all samples integrate with the Microsoft sample code browser.

A good example of this stuff is here in the iOS 11 maps sample: https://github.com/xamarin/ios-samples/tree/master/ios11/MapKitSample

For a cross-platform sample, please see: https://github.com/xamarin/mobile-samples/tree/master/Tasky

GitHub Integration

We integrate tightly with Git to make sure we always provide working samples to our customers. This is achieved through a pre-commit hook that runs before your commit goes through, as well as a post-receive hook on GitHub's end that notifies our samples gallery server when changes go through.

To you, as a sample committer, this means that before you push to the repos, you should run the "install-hook.bat" or "install-hook.sh" (depending on whether you're on Windows or macOS/Linux, respectively). These will install the Git pre-commit hook. Now, whenever you try to make a Git commit, all samples in the repo will be validated. If any sample fails to validate, the commit is aborted; otherwise, your commit goes through and you can go ahead and push.

This strict approach is put in place to ensure that the samples we present to our customers are always in a good state, and to ensure that all samples integrate correctly with the sample gallery (README.md, Metadata.xml, etc). Note that the master branch of each sample repo is what we present to our customers for our stable releases, so they must always Just Work.

Should you wish to invoke validation of samples manually, simply run "validate.windows" or "validate.posix" (again, Windows vs macOS/Linux, respectively). These must be run from a Bash shell (i.e. a terminal on macOS/Linux or the Git Bash terminal on Windows).

If you have any questions, don't hesitate to ask on Xamarin Forums!

More Repositories

1

Xamarin.Forms

Xamarin.Forms is no longer supported. Migrate your apps to .NET MAUI.
C#
5,641
star
2

xamarin-forms-samples

Sample apps built using the Xamarin.Forms framework
C#
4,305
star
3

xamarin-macios

.NET for iOS, Mac Catalyst, macOS, and tvOS provide open-source bindings of the Apple SDKs for use with .NET managed languages such as C#
C#
2,368
star
4

monodroid-samples

A collection of Xamarin.Android sample projects.
C#
2,197
star
5

XamarinComponents

Plugins for Xamarin
C#
1,988
star
6

xamarin-android

.NET for Android provides open-source bindings of the Android SDK for use with .NET managed languages such as C#
C#
1,867
star
7

XamarinCommunityToolkit

The Xamarin Community Toolkit is a collection of Animations, Behaviors, Converters, and Effects for mobile development with Xamarin.Forms. It simplifies and demonstrates common developer tasks building iOS, Android, and UWP apps with Xamarin.Forms.
C#
1,589
star
8

Essentials

Xamarin.Essentials is no longer supported. Migrate your apps to .NET MAUI, which includes Maui.Essentials.
C#
1,526
star
9

mobile-samples

C#
1,460
star
10

XobotOS

XobotOS - Android ported to C#
Java
1,246
star
11

xamarin-forms-book-samples

Code samples for "Creating Mobile Apps with Xamarin.Forms"
C#
731
star
12

docs-archive

Xamarin docs archive
Java
563
star
13

Xamarin.Auth

Xamarin.Auth
C#
544
star
14

urho

Code to integrate with the Urho3D engine
C#
463
star
15

app-crm

C#
384
star
16

urho-samples

Samples for the Urho bindings
C#
383
star
17

Sport

C#
358
star
18

Monkey.BluetoothLE

BluetoothLE abstraction for use with Xamarin projects, including Xamarin.Forms.
C#
348
star
19

mac-samples

Sample programs showing how to use Xamarin.Mac on OSX.
C#
323
star
20

GooglePlayServicesComponents

C#
307
star
21

WebSharp

Support for running C# on the web browser.
C#
302
star
22

mqtt

Minimalist and intuitive MQTT broker and client written entirely in C#
C#
297
star
23

dev-days-labs

C#
295
star
24

KimonoDesigner

Paint application using Xamarin.Mac and SkiaSharp
C#
260
star
25

SignaturePad

C#
246
star
26

GoogleApisForiOSComponents

C#
224
star
27

prebuilt-apps

Complete, prebuilt apps for you to customize and deploy.
C#
217
star
28

xamarin-forms-book-preview-2

Sample code for the 2nd Preview Edition of "Creating Mobile Apps with Xamarin.Forms"
C#
209
star
29

flex

Flex is a flexible box layout system written in C, designed to be easy to consume from other languages
C
191
star
30

Workbooks

C#
188
star
31

java.interop

Java.Interop provides open-source bindings of Java's Java Native Interface (JNI) for use with .NET managed languages such as C#
C#
183
star
32

AndroidX

AndroidX bindings for .NET for Android
C#
168
star
33

binding-tools-for-swift

C#
154
star
34

AndroidSupportComponents

Xamarin bindings for Android Support libraries - For AndroidX see https://github.com/xamarin/AndroidX
C#
145
star
35

XamarinStripe

Stripe.com .NET bindings
C#
134
star
36

Xamarin.Social

Xamarin.Social
C#
125
star
37

AngryNinjas

Angry Ninjas Cocos2D/XNA Sample
C#
120
star
38

customer-success-samples

Xamarin Customer Success
104
star
39

KinderChat

Secure Texting for Children
C#
98
star
40

VervetaCRM

Publicly available CRM demonstration app.
C#
97
star
41

ExposureNotification.Sample

A sample cross-platform mobile app and server for exposure notifications.
C#
94
star
42

mini-hacks

Complete four mini-hacks during Evolve and get a prize.
C#
89
star
43

PortableRazor

A lightweight implementation of ASP.NET MVC APIs for mobile devices.
C#
89
star
44

FacebookComponents

C#
86
star
45

Seminars

Sample code used in the Xamarin Seminars
C#
68
star
46

amazon

Library for accessing Amazon web services from mobile apps
C#
62
star
47

xamarin-forms-book-preview

Sample code for the Preview Edition of "Creating Mobile Apps with Xamarin.Forms"
C#
61
star
48

mac-ios-samples

Samples targeting both iOS and OSX that share code.
C#
57
star
49

XamarinAzureChallenge

Create an iOS/Android app using Xamarin.Forms and connect it to a serverless Azure Function
C#
56
star
50

Touch.Unit

NUnitLite based runner for unit testing .NET code under iOS
C#
50
star
51

google-apis

Google API bindings for Xamarin.
C#
47
star
52

xamarin-evolve-2014

Slides, Demos and Training samples for Evolve 2014 from Xamarin University
C#
45
star
53

mobcat

43
star
54

Rivets

A C# implementation of App Links, functionally, a port of Bolts
C#
43
star
55

app-xamarintv

Xamarin.Forms app demonstrating the dual-screen device capability for neo and duo devices
C#
42
star
56

Xamarin.Forms.CarouselView

C#
41
star
57

Xamarin.Forms.GraphQL

C#
41
star
58

evolve-quest

Evolve Quest is an iBeacon based scavenger hunt that attendees enjoyed at Evolve 2014
C#
35
star
59

android-activity-controller

C#
35
star
60

xamarin-iot-samples

Samples for Xamarin IoT
C#
35
star
61

monotouch-element-pack

A place to host various MonoTouch.Dialog.Elements that users can use.
C#
35
star
62

Xamarin.Forms-api-docs

Xamarin.Forms API documentation in ECMA XML format
PowerShell
34
star
63

PortableRazorStarterKit

A starter kit for PortableRazor.
JavaScript
34
star
64

Xamarin.Legacy.Sdk

Starting from a .NET 6 project, adds the ability to target legacy Xamarin target frameworks such as monoandroid11.0 or xamarin.ios10. *Not fully supported*
34
star
65

SalesforceSDK

Salesforce SDK component
C#
31
star
66

LibZipSharp

A managed wrapper (and then some) around libzip (https://libzip.org/)
C#
28
star
67

xamarin-android-tools

C#
28
star
68

benchmarker

A simple benchmarking and comparison tool
C#
26
star
69

apple-api-docs

Xamarin.iOS & Xamarin.Mac API documentation in ECMA XML format
F#
26
star
70

sketches

Xamarin Sample Sketches
26
star
71

Xamarin.MacDev

Support libraries for xamarin-macios
C#
25
star
72

mirepoix

A small collection of utility APIs including command line argument splitting and quoting, file system globbing, cross platform process execution, and console output redirection handling.
C#
25
star
73

Xamarin.PropertyEditing

C#
24
star
74

xamarinu-connect2016

C#
23
star
75

app-customers

A simple demo app with three screens: a list screen, a read-only detail screen, and an editable detail screen.
C#
23
star
76

xunit

xUnit
C#
22
star
77

MyCompany

C#
22
star
78

jar2xml

Java Archive API extraction tool
Java
19
star
79

android-api-docs

Android API documentation
PowerShell
19
star
80

demo-xamarincrm

C#
19
star
81

Urho3D

Clone of the Urho3D repository
C++
19
star
82

XamarinAndroidXMigration

Build tasks and tools to support Xamarin.Android AndroidX migration
C#
18
star
83

xamarin-evolution

Maintains proposals for changes to the Xamarin SDKs (Android, iOS, Forms, Components, Urho, Skia)
18
star
84

dropbox-sync-component

C#
18
star
85

vs-mono-debugger-sample

Sample showing how to use the Visual Studio Mono Debugger for your own Mono-based project types
C#
17
star
86

DocWriter

Desktop Editor for the ECMA XML Documentation
C#
16
star
87

evolve-presentation-template

Evolve 2016 Presentation Templates
HTML
15
star
88

SaveTheDate

C#
14
star
89

xamarin-windows

Provides reusable MSBuild tasks and sample Visual Studio tooling for building and debugging Mono AOT compiled binaries
C#
14
star
90

fsharpbinding

F# binding for MonoDevelop (updated to support Xamarin Studio)
F#
14
star
91

Windows.Injector

Allows injecting .NET code into a remote process in Windows
C++
13
star
92

web-tests

C#
12
star
93

md-xamarin-fsharp-addins

F# magic
F#
11
star
94

fsharp-iOS-designer

iOS designer integration for F#
F#
11
star
95

moq

The most popular and friendly mocking library for .NET and Xamarin
C#
9
star
96

sales-uitest-extensions

Extension methods for UITest
C#
7
star
97

component-template

A sample template that you can use as a guide to create your own components.
Ruby
7
star
98

xamarin-android-binutils

LLVM toolchain for Xamarin.Android
C++
7
star
99

evolve-2014-presentation-template

Evolve 2014 Presentation Template
7
star
100

emscripten-test

C
6
star