From a25d1b856133d4ab8b7fef3b951d7ca3a47cc088 Mon Sep 17 00:00:00 2001 From: Maxime Thirouin Date: Wed, 29 Jan 2020 10:40:53 +0100 Subject: [PATCH] @reason-react-native/template @ 0.61.0 --- CHANGELOG.md | 7 ++++- README.md | 11 +++++--- package.json | 28 +++++++++++-------- .../ios/ProjectNameTests/ProjectNameTests.m | 2 ++ template/package.json | 7 +++-- yarn.lock | 5 ++++ 6 files changed, 41 insertions(+), 19 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3191b11..8e8a78b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,9 @@ -# reason-react-native-template CHANGELOG +# Changelog of `@reason-react-native/template` + +## 0.61.0 - 2019-06-17 + +- Rename `reason-react-native-template` to `@reason-react-native/template` +- Bump to `react-native@0.61.0` & `reason-react-native@0.61.0` ## 0.1.0 - 2019-06-17 diff --git a/README.md b/README.md index cfc8858..3b64670 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,9 @@ -# Reason React Native HelloWorld +# `@reason-react-native/template` -> This is a React Native application developed in Reason. +[![Version](https://img.shields.io/npm/v/@reason-react-native/template.svg)](https://www.npmjs.com/@reason-react-native/template) +[![Chat](https://img.shields.io/discord/235176658175262720.svg?logo=discord&colorb=blue)](https://reason-react-native.github.io/discord/) + +> React Native template for application developed in Reason. Please carefully read instructions below in order to enjoy ReasonML development experience. @@ -10,7 +13,7 @@ experience. ## Start a Reason React Native project with this template ```console -npx react-native init MyApp --template reason-react-native-template +npx react-native init MyApp --template @reason-react-native/template cd MyApp ``` @@ -26,4 +29,4 @@ yarn global remove react-native-cli ``` Now that you are ready to go, you can check our documentation on -[how to use Reason React Native](https://reasonml-community.github.io/reason-react-native/en/docs/usage/). +[how to use Reason React Native](https://reason-react-native.github.io/en/docs/usage/). diff --git a/package.json b/package.json index 2514103..f0f7d36 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,9 @@ { - "name": "reason-react-native-template", - "version": "0.1.0-beta.3", + "name": "@reason-react-native/template", + "version": "0.61.0", + "publishConfig": { + "access": "public" + }, "license": "MIT", "keywords": [ "reason", @@ -21,20 +24,19 @@ "!template/lib/ocaml" ], "devDependencies": { - "bs-platform": "^5.0.4", - "husky": "^1.3.1", - "lerna": "^3.4.0", - "lint-staged": "^8.1.5", - "npm-run-all": "^3.0.0", - "prettier": "^1.16.4" + "bs-platform": "^7.0.0", + "husky": "^1.3.0", + "lint-staged": "^8.1.0", + "npmpub": "^5.0.0", + "prettier": "^1.18.0" }, "scripts": { + "prepare": "cd template && yarn", + "test": "cd template && yarn re:build && yarn test", "format:most": "prettier --write \"**/*.{md,json,js,css}\"", "format:re": "find . -name \"*.re\" -or -name \"*.rei\" | grep -v \"node_modules\" | xargs bsrefmt --in-place", "format": "yarn format:most && yarn format:re", - "test": "cd template && yarn test", - "#prepublishOnly": "this is to include debug.keystore for android. Using files here doesn't work as .gitignore of the other folder seems to be *stronger*", - "prepublishOnly": "rm -f template/.npmignore && grep -w -v \"*.keystore\" template/.gitignore > template/.npmignore" + "release": "npmpub" }, "prettier": { "trailingComma": "all", @@ -42,7 +44,8 @@ }, "lint-staged": { "*.{md,json,js,css}": [ - "prettier --write" + "prettier --write", + "git add" ], "*.{re,rei}": [ "bsrefmt --in-place", @@ -55,3 +58,4 @@ } } } + diff --git a/template/ios/ProjectNameTests/ProjectNameTests.m b/template/ios/ProjectNameTests/ProjectNameTests.m index 499deef..da8f608 100644 --- a/template/ios/ProjectNameTests/ProjectNameTests.m +++ b/template/ios/ProjectNameTests/ProjectNameTests.m @@ -59,9 +59,11 @@ - (void)testRendersWelcomeScreen return NO; }]; } + #ifdef DEBUG RCTSetLogFunction(RCTDefaultLogFunction); #endif + XCTAssertNil(redboxError, @"RedBox error: %@", redboxError); XCTAssertTrue(foundElement, @"Couldn't find element with text '%@' in %d seconds", TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS); } diff --git a/template/package.json b/template/package.json index d39d333..78ef18a 100644 --- a/template/package.json +++ b/template/package.json @@ -22,13 +22,16 @@ "@babel/runtime": "^7.6.2", "@react-native-community/eslint-config": "^0.0.5", "babel-jest": "^24.9.0", - "bs-platform": "^5.0.4", + "bs-platform": "^7.0.0", "eslint": "^6.5.1", "jest": "^24.9.0", "metro-react-native-babel-preset": "^0.56.0", "react-test-renderer": "16.9.0" }, "jest": { - "preset": "react-native" + "preset": "react-native", + "transformIgnorePatterns": [ + "node_modules/(?!(jest-)?react-native|react-(native|universal|navigation)-(.*)|@react-native-community/(.*)|@react-navigation/(.*)|bs-platform)" + ] } } diff --git a/yarn.lock b/yarn.lock index 00ee59e..caf01ca 100644 --- a/yarn.lock +++ b/yarn.lock @@ -173,6 +173,11 @@ braces@^2.3.1: split-string "^3.0.2" to-regex "^3.0.1" +bs-platform@^7.0.0: + version "7.0.1" + resolved "https://registry.yarnpkg.com/bs-platform/-/bs-platform-7.0.1.tgz#1d7b0ef6088b998dceee5db74a7cd8f01c20a3bd" + integrity sha512-UjStdtHhbtC/l6vKJ1XRDqrPk7rFf5PLYHtRX3akDXEYVnTbN36z0g4DEr5mU8S0N945e33HYts9x+i7hKKpZQ== + cache-base@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/cache-base/-/cache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2"