components react native code example
Example 1: react native routes
import { createSwitchNavigator } from 'react-navigation';
Example 2: core components of api
1-An action showing HTTP methods like
GET, PUT, POST, DELETE.
2-Uniform Resource Identifier (URI),
which is the identifier for the resource on the server.
3-HTTP Version, which indicates HTTP
version, for example-HTTP v1.1.
4-Request Header, which carries metadata
(as key-value pairs) for the HTTP Request message.
Metadata could be a client (or browser) type,
format supported by the client, format
of a message body format,
cache settings, and so on.
5-Request Body, which indicates the
message content or resource representation.
Example 3: react native components
Example 4: components react to hooks
import React, { useState } from 'react';
function Example() {
return (
<div>
<p>You clicked {count} times</p>
<button onClick={() => setCount(count + 1)}>
Click me
</button>
</div>
);
}