<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Tim Kendall on Medium]]></title>
        <description><![CDATA[Stories by Tim Kendall on Medium]]></description>
        <link>https://medium.com/@tboytim?source=rss-8b4997d13a49------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*eH6zdbAXkMB0thBn.jpeg</url>
            <title>Stories by Tim Kendall on Medium</title>
            <link>https://medium.com/@tboytim?source=rss-8b4997d13a49------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 27 Nov 2026 17:09:31 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@tboytim/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Ionic.js Platform Styles]]></title>
            <link>https://medium.com/@tboytim/ionic-js-platform-styles-5e88f4a63202?source=rss-8b4997d13a49------2</link>
            <guid isPermaLink="false">https://medium.com/p/5e88f4a63202</guid>
            <dc:creator><![CDATA[Tim Kendall]]></dc:creator>
            <pubDate>Tue, 01 Jul 2014 21:34:59 GMT</pubDate>
            <atom:updated>2014-07-01T21:35:29.160Z</atom:updated>
            <content:encoded><![CDATA[<h4>Platform specific styles with the Ionic Framework</h4><p><em>Ran into this issue the other day and figured I’d share my solution</em>. The beauty of hybrid mobile apps is being able to share 90% of your codebase between platforms. However if you’ve worked on a larger project you may have run into the need for platform specific styles.</p><p>In my solution I wanted to use SASS and also keep the platform specific styles in separate files. The solution is in two parts:</p><ol><li>Edit the included <strong>gulpfile.js</strong> to watch multiple stylesheets</li></ol><pre>gulp.task(‘sass’, function(done) {<br> gulp.src(<strong>[‘./scss/ionic.android.app.scss’,‘./scss/ionic.ios.app.scss’]</strong>)<br> .pipe(sass())<br> .pipe(gulp.dest(‘./www/css/’))<br> .pipe(minifyCss({<br> keepSpecialComments: 0<br> }))<br> .pipe(rename({ extname: ‘.min.css’ }))<br> .pipe(gulp.dest(‘./www/css/’))<br> .on(‘end’, done);<br>});</pre><p>2. Include some logic in <strong>index.html </strong>to load the correct stylesheet (note: make sure this script is placed after <em>ionic.bundle.js; shown below)</em></p><pre><em>&lt;!— ionic/angularjs js →<br></em>&lt;script src=”lib/ionic/js/ionic.bundle.js”&gt;&lt;/script&gt;</pre><pre>&lt;!— Load platform specific styles →<br>&lt;script&gt;<br>  // Utilize Ionic’s methods for determining platform<br>  if (ionic.Platform.isAndroid()) {<br>    // Android styles<br>    document.write(‘&lt;link href=”css/ionic.android.app.css”  rel=”stylesheet”&gt;’);<br>  } else if (ionic.Platform.isIOS()) {<br>   // iOS Styles<br>   document.write(‘&lt;link href=”css/ionic.ios.app.css” rel=”stylesheet”&gt;’);<br>  } else {<br>   // Browser development styles (use Android)<br>   document.write(‘&lt;link href=”css/ionic.android.app.css” rel=”stylesheet”&gt;’);<br>  }<br>&lt;/script&gt;</pre><p>And that’s it! I’m sure there are probably more elegant ways to do this but hopefully you find it useful.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5e88f4a63202" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>