TypeError: cli.init is not a function

I’m trying to create a react-native project on windows, but I’m getting this error. TypeError: cli.init is not a function at run (C:\Users\oktay\AppData\Roaming\npm\node_modules\react-native-cli\index.js:302:7) at createProject (C:\Users\oktay\AppData\Roaming\npm\node_modules\react-native-cli\index.js:249:3) at init (C:\Users\oktay\AppData\Roaming\npm\node_modules\react-native-cli\index.js:200:5) at Object.<anonymous> (C:\Users\oktay\AppData\Roaming\npm\node_modules\react-native-cli\index.js:153:7) at Module._compile (node:internal/modules/cjs/loader:1155:14) at Object.Module._extensions..js (node:internal/modules/cjs/loader:1209:10) at Module.load (node:internal/modules/cjs/loader:1033:32) at Function.Module._load (node:internal/modules/cjs/loader:868:12) at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12) at node:internal/main/run_main_module:22:47 Based on the react… Read More TypeError: cli.init is not a function

In react native @react-navigation/native-stack error occured

I was trying to input ‘npm install @react-navigation/native-stack’ In my vscode’s terminal to install @react-navigation/native-stack but during installing, error occured. The following is error message. npm ERR! code 128 npm ERR! An unknown git error occurred npm ERR! command git –no-replace-objects ls-remote ssh://git@github.com/react-navigation/native-stack.git npm ERR! ERROR: Repository not found. npm ERR! fatal: Could not read… Read More In react native @react-navigation/native-stack error occured

Issue on Hide/Show component in React Native

I am new in React native development and i am trying to do something simple. I have 4 components <TouchableOpacity> in a React Class extending Component. In the render function, i am trying to hide three of these components while i am pressing on one. render(){ […] return ( <TouchableOpacity style={styles.filterButtonAll} onPress={()=>this.toggleStatus()}> <Ionicons size={15} name=’XXX’>… Read More Issue on Hide/Show component in React Native

TypeError: undefined is not an object (evaluating 'items.map')

After receiving items, the following error occurs. At the moment I’m just learning and have looked at other answers on this topic, nothing comes up. export default function App() { const [items, setItems] = React.useState(); React.useEffect(() => { axios .get(‘https://62fa26ddffd7197707e66da8.mockapi.io/items&#8217;) .then(({ data }) => { setItems(data); }) .catch((err) => { console.log(err); Alert.alert(‘Ошибка’, ‘Ошибка при получении… Read More TypeError: undefined is not an object (evaluating 'items.map')

React Native change style on disabled button

How can i change button opacity to 0.5 if the button is disabled? Should i somehow add buttonDisabled style to the TouchableOpacity? What would be the best way and how to do it? type IconButtonProps = { name: IconN<44>; disabled?: boolean; } export function IconButton(props: IconButtonProps) { return ( <View style={styles.container} > <TouchableOpacity disabled={!props.disabled}> <View>… Read More React Native change style on disabled button

Need to check all my variables for an ampersand, I put variables in a list and check using a for loop, but Python only changes value inside list

I’ve got the following code, but unfortunately it only changes the value inside the list. Is there any way I can change the value outside the list, so it can be used later in the script? street_number = "100 & 102" street_name = "Fake Street" suburb = "Faketown" allvariables = [street_number, street_name, suburb] ampersand =… Read More Need to check all my variables for an ampersand, I put variables in a list and check using a for loop, but Python only changes value inside list