Crowd-sourced code mentorship. Practice having thoughtful conversations about code.
:gem: Library to create media type definitions, schemes and validations
Lidgren srp6a implementation that uses a lobby to seperate authenticated users from guests.
Gigabase: Synthetic Biology Cell Modeling Project
it pretty
Oh yeah, I know what it is ;)
[elyses-enchantments] Be super explicit about mutation+return (#2066)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
As some people are getting stuck/confused by the fact that the functions should both mutate and return, let's be super-specific about it.
/format
you're code ugly @iHiD
@nikshirobokov thank you; yes, that includes the patch I posted, so you're good to go!
FWIW, I did try out the build hooks solution myself, because Yarn 3, even with node_modules
linker, is fast on my system. You can see the result here:
Duplicate of #6529
Yeah, yarn 2+ cannot be installed directly like that. EAS will need to change its infrastructure slightly to make that work via the prop.
Only the set version thing works I think, as that's what yarn says in their own documentation!
@nikshirobokov that is a good question.
You can first try to set the yarn
version via the yarn eas.json
option (documentation linked), and if that doesn't work, try it by switching (installing) version via eas-build-pre-install
(documentation linked) hook.
Can you let me know if either works? I'll be needing this soon.
Hi Dylan!
Short form answer is here: https://github.com/exercism/javascript/issues/1770 Long form answer and discussion is here: http://forum.exercism.org/t/discouraged-code-practice-found-in-elyses-enchantments/242/8
Feel free to respond on the forum or open a new topic there to discuss further if you would like so :)
@MaxRobertsDear do you happen to be on Windows?
My first guess would be windows, and this being a cli issue, and not, like Evan said, being a router issue.
I'm on windows 11, cmd.exe terminal (since we no longer have the metro ui).
My second guess would be a difference between real devices and emulators. I was using a real device. I can test this if you like.
Third guess would be not OS, but terminal related. I have a machine at the office with 6 windows terminals, some of which are more unix-compatible than others. @brentvatne for this I can do a test against all of them next week if you like.
Are you saying it's expected that logs are swallowed completely (not showing up)?
I would like to re-open this issue in the appropriate place. Would that be expo-cli
? Please note that the problem is not the amount of logs or duplicates. It's that this example project generates NO logs after the first one, when running on Android.
@triangletrianglesquareplusx would you still like to apply some if not all of the suggestions given in the review?
FYI, this is still present in 5.1.4
.
Yarn 3
offers an out-of-box experience for patches, so if you're using that, here is how I generated and applied the patch for that version:
yarn set version stable
.yarnrc.yml
has nodeLinker: node-modules
.gitignore
doesn't ignore patches
and releases
yarn patch react-native-paper
.yarn/patches/react-native-paper-npm-5.1.4-df7f4a3886.patch
"resolutions"
to package.json
: "react-native-paper@^5.1.4": "patch:react-native-paper@npm%3A5.1.4#./.yarn/patches/react-native-paper-npm-5.1.4-df7f4a3886.patch"
yarn install
again to apply(Apologies for the styling changes. It happened automatically because of the prettier
config in the tree)
If you want to apply this patch yourself, you don't need to go through the above steps if you already use Yarn 3
. Instead, copy the patch
below to the same path, add the resolutions
entry, and run yarn install
.
diff --git a/lib/commonjs/components/TextInput/TextInput.js b/lib/commonjs/components/TextInput/TextInput.js
index 6aa8423edec6e1ccd09b4b5b929f1c72eb6fb296..bc535893243324f4cb48a4d739a7fc5eef78ddd9 100644
--- a/lib/commonjs/components/TextInput/TextInput.js
+++ b/lib/commonjs/components/TextInput/TextInput.js
@@ -274,7 +274,8 @@ const TextInput = (0, _forwardRef.forwardRef)((_ref, ref) => {
render: render
}, rest, {
theme: theme,
- value: value,
+ defaultValue: isControlled ? undefined : value,
+ value: isControlled ? value : undefined,
parentState: {
labeled,
error,
@@ -308,7 +309,8 @@ const TextInput = (0, _forwardRef.forwardRef)((_ref, ref) => {
render: render
}, rest, {
theme: theme,
- value: value,
+ defaultValue: isControlled ? undefined : value,
+ value: isControlled ? value : undefined,
parentState: {
labeled,
error,
diff --git a/lib/module/components/TextInput/TextInput.js b/lib/module/components/TextInput/TextInput.js
index 7c413a8ec10d5a6270d9b3da0cc15cf583624d55..ed5d3090b7c448028ded03949f150f6db3ed86a1 100644
--- a/lib/module/components/TextInput/TextInput.js
+++ b/lib/module/components/TextInput/TextInput.js
@@ -265,7 +265,8 @@ const TextInput = forwardRef((_ref, ref) => {
render: render
}, rest, {
theme: theme,
- value: value,
+ defaultValue: isControlled ? undefined : value,
+ value: isControlled ? value : undefined,
parentState: {
labeled,
error,
@@ -299,7 +300,8 @@ const TextInput = forwardRef((_ref, ref) => {
render: render
}, rest, {
theme: theme,
- value: value,
+ defaultValue: isControlled ? undefined : value,
+ value: isControlled ? value : undefined,
parentState: {
labeled,
error,
diff --git a/src/components/TextInput/TextInput.tsx b/src/components/TextInput/TextInput.tsx
index 1398d8b0046087577be80b636d6dc0161d0a967e..001c04b923364c7f518a1b4640cc84e6ffd499d0 100644
--- a/src/components/TextInput/TextInput.tsx
+++ b/src/components/TextInput/TextInput.tsx
@@ -1,4 +1,4 @@
-import * as React from 'react';
+import * as React from "react";
import {
Animated,
LayoutChangeEvent,
@@ -6,20 +6,20 @@ import {
TextInput as NativeTextInput,
TextStyle,
ViewStyle,
-} from 'react-native';
+} from "react-native";
-import { useInternalTheme } from '../../core/theming';
-import type { ThemeProp } from '../../types';
-import { forwardRef } from '../../utils/forwardRef';
+import { useInternalTheme } from "../../core/theming";
+import type { ThemeProp } from "../../types";
+import { forwardRef } from "../../utils/forwardRef";
import TextInputAffix, {
Props as TextInputAffixProps,
-} from './Adornment/TextInputAffix';
+} from "./Adornment/TextInputAffix";
import TextInputIcon, {
Props as TextInputIconProps,
-} from './Adornment/TextInputIcon';
-import TextInputFlat from './TextInputFlat';
-import TextInputOutlined from './TextInputOutlined';
-import type { RenderProps, TextInputLabelProp } from './types';
+} from "./Adornment/TextInputIcon";
+import TextInputFlat from "./TextInputFlat";
+import TextInputOutlined from "./TextInputOutlined";
+import type { RenderProps, TextInputLabelProp } from "./types";
const BLUR_ANIMATION_DURATION = 180;
const FOCUS_ANIMATION_DURATION = 150;
@@ -33,7 +33,7 @@ export type Props = React.ComponentPropsWithRef<typeof NativeTextInput> & {
* In `outlined` mode, the background color of the label is derived from `colors?.background` in theme or the `backgroundColor` style.
* This component render TextInputOutlined or TextInputFlat based on that props
*/
- mode?: 'flat' | 'outlined';
+ mode?: "flat" | "outlined";
left?: React.ReactNode;
right?: React.ReactNode;
/**
@@ -173,7 +173,7 @@ interface CompoundedComponent
type TextInputHandles = Pick<
NativeTextInput,
- 'focus' | 'clear' | 'blur' | 'isFocused' | 'setNativeProps'
+ "focus" | "clear" | "blur" | "isFocused" | "setNativeProps"
>;
/**
@@ -224,7 +224,7 @@ type TextInputHandles = Pick<
const TextInput = forwardRef<TextInputHandles, Props>(
(
{
- mode = 'flat',
+ mode = "flat",
dense = false,
disabled = false,
error: errorProp = false,
@@ -249,7 +249,7 @@ const TextInput = forwardRef<TextInputHandles, Props>(
);
const [focused, setFocused] = React.useState<boolean>(false);
const [placeholder, setPlaceholder] = React.useState<string | undefined>(
- ' '
+ " "
);
const [uncontrolledValue, setUncontrolledValue] = React.useState<
string | undefined
@@ -344,7 +344,7 @@ const TextInput = forwardRef<TextInputHandles, Props>(
// Root cause: Placeholder initial value, which has length 0.
// More context: The issue was also reproduced in react-native, using its own TextInput.
// Workaround: Set an empty space character in the default value.
- setPlaceholder(' ');
+ setPlaceholder(" ");
}
return () => {
@@ -436,7 +436,7 @@ const TextInput = forwardRef<TextInputHandles, Props>(
const { maxFontSizeMultiplier = 1.5 } = rest;
- if (mode === 'outlined') {
+ if (mode === "outlined") {
return (
<TextInputOutlined
dense={dense}
@@ -447,7 +447,8 @@ const TextInput = forwardRef<TextInputHandles, Props>(
render={render}
{...rest}
theme={theme}
- value={value}
+ defaultValue={isControlled ? undefined : value}
+ value={isControlled ? value : undefined}
parentState={{
labeled,
error,
@@ -484,7 +485,8 @@ const TextInput = forwardRef<TextInputHandles, Props>(
render={render}
{...rest}
theme={theme}
- value={value}
+ defaultValue={isControlled ? undefined : value}
+ value={isControlled ? value : undefined}
parentState={{
labeled,
error,
@ErikSchierboom you probably want to move this to go-test-runner
Using Printf
function from fmt
has stopping remaining running test case and allowed for submit which lead to false positive case.
Link: https://exercism.org/tracks/go/exercises/need-for-speed