Skip to content

Instantly share code, notes, and snippets.

View jamesnyika's full-sized avatar
🛬
Approaching Doha

Deus Eks jamesnyika

🛬
Approaching Doha
View GitHub Profile

Keybase proof

I hereby claim:

  • I am jamesnyika on github.
  • I am jnyika (https://keybase.io/jnyika) on keybase.
  • I have a public key ASAGwTIHyAhjWTqCaSSvbVkbv9utH7Y_pDUHaQbnjn77Mgo

To claim this, I am signing this object:

@jamesnyika
jamesnyika / Clojurescript & React Navigation 3.md
Last active April 7, 2024 01:06
Using React Navigation 3 with Clojurescript

React Navigation in Clojurescript

I have been using v2 of React navigation for some time but needed to find a good article or source describing how to integrate it into a clojurescript project using Reagent, Re-frame, Shadow-cljs and no Leiningen or Figwheel. No offence to those libraries and tools, I just wanted to use Shadow so that I could also take advantage of the easy use of deps.edn. So how do you use React Navigation v3 in CLJS ?

Install Stuff

Make sure you have a project setup and install React Navigation using yarn or npm. I will not cover this. Please see this basic project setup from the shadow site as a reference :

Shadow CLJS Examples

The Basic Setup

@jamesnyika
jamesnyika / cross-browser-flip-card.markdown
Created January 9, 2019 03:13
Cross-Browser Flip Card

Cross-Browser Flip Card

A GSAP powered cross-browser 3D flip card sample.

Basically it uses two different elements that are animated at the same time to create the flip card, without using preserve-3d which is not supported by IE.

A Pen by Rodrigo Hernando on CodePen.

License.

@jamesnyika
jamesnyika / React Navigation V3+ in Clojurescript.md
Last active November 16, 2020 14:10
React Navigation V3+ in Clojurescript

React Navigation is a great component for building mobile applications. It is versatile and supports both dominant platforms beautifully. However, despite the 2 libraries that exist out there to support this component in the Clojure ecosystem, there is sadly very little documentation on what and how you can set up and use this component. I could not get them to work for me (my failing) so I decided to try and make it work without the existing libraries just to that I can understand what is going on. Below is a laying out of my experience. Let me know if you have corrections so that we mortals who are not that sharp can learn.

React Navigation requires an exact set of steps to make it successfully work

Step 1: Installation of React Navigation

Use yarn to add the library to the project

@jamesnyika
jamesnyika / Expo, NativeBase and Clojurescript (using Re-frame).md
Last active September 1, 2023 17:38
Expo, NativeBase and Clojurescript (using Re-frame)

Expo and Native Base are fantastic environments for designing mobile applications. However, there are still many challenges that you will face in attempting to build an application with them. Just to make it a little harder, try doing it in Clojurescript where you have to translate what you would ordinarily do in Javascript..in Clojurescript instead.

In this short gist, I wanted to highlight some things you are going to see often. Very often and how to get around them.

Before we begin

  • You will notice a lot of namespaces names ui or uic or mod. I have separated in different files my library imports (mod namespace) from the actual component configuration (ui namespace) from the compositing of multiple components (uic namespace). So be mindful of that and do not just copy blindly. in most cases you if you want to use the code as is, all you need to do is strip out my namespaces before making calls.

  • I have only been testing with the IOS simulator. I have no

@jamesnyika
jamesnyika / Datomic-HSQLDB Storage.md
Last active June 14, 2018 16:55
Datomic - HSQLDB Storage Setup

Howto - Setting Up an HSQLDB Storage for Datomic

This gist walks you through the steps of setting up a storage for your datomic starter instance to use an HSQLDB instance (running as a standalone server - i do not address embedded, http, in memory or other forms of the server). I am sure the same can be applied to any other SQL based storage so it should be portable to Apache Derby. I am writing this for those who may find it useful in getting this done quickly without spending a week as I did trying to figure out what I was doing wrong.

Part I : Install & Setup Your Storage: the HSQLDB Server

  1. Download the latest version of the database from here
  2. The most important file you will need is the hsqldb.jar file. This is the database. This will need to be in your classpath to be able to run the server.
  3. I then create a bash script for easy execution of the Network Server version of the database as shown below.