Monthly Archives: June 2016

NativeScript: Patreon Posts & Plugins

For those who are unaware; I've started doing paid content; see my post on "Why Patreon" to see the reasons.   I'm going to attempt to keep this post updated with plugins and posts that are available to those who are my patreon supporters.

Posts:

 

Plugins:

 

NativeScript 2.1 released (and common issues/fixes)

WooHoo, 2.1 is finally released.  Lots of things fixed and several other cool new things added; here is some of the changes in v2.1;

  • TNS Clean command!
  • Fix for faster Building (really affects Angular 2 builds)
  • Fix for Google library and default Config issues.
  • several naviation crashing issues fixed
  • several LiveSync issues fixed
  • Lots of other fixes

Now to install this awesome new release in four simple steps:

  1. Install the new version of the NativeScript command line
    • npm install -g nativescript@latest
  2. Remove the existing platform(s)
    • tns platform remove android
      AND/OR
    • tns platform remove ios
  3. Add the platform(s) you need
    • tns platform add android
      AND/OR
    • tns platform add ios
  4. Install the common core modules
    • npm install tns-core-modules@latest --save

 

A couple issues have cropped up in NativeScript 2.1.0 -- Here are the issues with the solutions

  1. If you see "error: constructor RunTimeHelper in class RuntimeHelper cannot be applied to given types" or "com.tns.Runtime runtime = new RuntimeHelper(this).initRuntime();" or "reason: actual and formal argument lists differ in length"
  • This means one of the above is out of sync with the others; all three pieces of the puzzle MUST be 2.1.0 or later.   This is one of those upgrades that requires everything to be in sync.

2. If your app fails to deploy to the phone or android emulator

  • This means one of the above is out of sync with the others; again all three NativeScript pieces MUST be 2.1.0 or later.

3. Missing CFBundleShortVersionString / CFBundleVersion on iOS

  • Open xcode, then open up the file platforms/ios/Internal/NativeScript.framework/Info.plist then add both the keys, and set them to 2.1.0
  • Or once iOS 2.1.1 runtimes has been released; upgrade to the 2.1.1 iOS runtimes.

4. Error: java.lang.runtimeException:Unable to create application
with next error being   Java.lang.ClassNotFoundException com.tns.FragmentClass

  • npm install tns-core-modules@latest --save
    Then you can build/run it as normal.

5, No errors, but no deploy either (android)

  • npm remove -g nativescript
  • npm cache clean
  • npm install -g nativescript
  • tns platform clean android   <-- Done inside your project

NativeScript: Why Patreon?

community-nativescriptHi, thanks for stopping by and hopefully this blog post will answer the question; NativeScript: "Why Patreon?"

I think it goes without saying that I have been a valuable participant in the Nativescript community since NativeScript was first released. However, for those who don't know who I am, here is a really quick summary. I wrote the book on NativeScript. I currently hold the record for the most developed NativeScript plugins and plugin assists. I created and maintain the community NativeScript web site including the cool plugins library at Nativescript.rocks. In addition I have dozens of in-depth posts regarding NativeScript on my blog as well as innumerable support posts on Google Groups, Slack, and I have one of the highest NativeScript support ratings on StackOverflow. I can continue to go on, but I think from this you get a pretty good picture of what I've contributed.

And here is a small trimmed down list of things I would like to pursue in the future for the NS community.

Blogs:
- How to use Android Extend's properly
- How to do Extend'd events properly in Android JS
- iOS and Android Gotcha's
- Building a AAR from a JAR and/or Source code (Android)
- Building a Full interface plugin in Android/ios (Using a maven/cocoapod)
- Building a Full interface plugin (totally in TypeScript/JavaScript)
- Techniques to optimizing your code
- Angular 2 and using normal processing or interface NativeScript plugins
- iOS & Android Multithreading

Tools/Plugins:
- Shrink the size of deployed APK/IPA size (post-hook tool)
- iOS WKWebView & Safari View Controller
- Android Camera control 2
- PDF control
- Fluent Reports (data driven JS reporting engine)
- Encrypted Key Store access & native encryption routines
- Convert more/all of the Node modules
- Debugging, Design, and Performance tools
- LiveEdit for iOS & better TypeScript support (TSLint)
- Replacing "Observable/ObservableArray/Promises" in NativeScript with RxJS
- Deployed remote updating (i.e. download updates to your app from your server)

NativeScript.rocks:
- Searchable/Filterable/Sortable
- Mobile friendly & Mobile app w/ runnable samples
- Pictures/Animations of interface plugins
- Display docs

What many of you may not know is that I am a totally self employed family man. That's right, I don't have a 9-5 regular paying gig. I'm a husband and father to several kids, with another due in Aug. So, I am at a point where I need to focus in one direction or the other. I've spent a lot of time on the community and I have really enjoyed it. As you can see I have so many great ideas for so many more NativeScript blogs, tools and plugins. But, I also need to take care of my family, so I need to pay the bills. This is where you can come in and help! You can choose to help me build many more free resources in the NativeScript community. By pledging to my Patreon fund.  You can show that you appreciate all open source plugins, knowledge, web sites, and finally the support that I bring to our community.

The goals I have currently setup are:
- $100 - A exclusive blog post each month
- $500 - Several exclusive blog posts each month
- $1,000 - A plugin each month, exclusive to patreon's for at least 3 months.
- $2,500 - I'll work on a free book for the community, 3 months exclusive for patreon's
- $4,000 - A complicated plugin/tool for the community, or several simpler plugins per month. (Again exclusive for patreon's for at least 3 months)

Each of these goals will be using your suggestions and/or from my list and voted on by you patreon's; so you can direct the direction and potentially get answers and/or plugins to fill the need you have or see.

This does not mean that if I don't get the funding that I'm leaving. I love NativeScript! We have an awesome community; so I'm sticking around. Rather it just means I will have to refocus the majority of my time on other stuff like generating contracts, making commercial plugins, services, and things like paid training.

I have been been working on transitioning to primarily commercial -- however, I decided to try a grand experiment. I am going to let you as the NativeScript community choose where you would like me to focus my time and efforts...

If you choose to support me; here is my Patreon Link.