In ReactJS, you can handle arrays and strings in different ways.
1. Arrays: An array in ReactJS is commonly used to store (and later display) a list of items. You can create an array in your component’s state, typically using the useState or this.state methods. Making use of the JavaScript `.map() function`, you can iterate over your array to generate a new array of JSX elements.
For example,
```
const numbers = [1, 2, 3, 4, 5];
const listItems = numbers.map((number) =>
ReactDOM.render(
1. Strings: Strings can be rendered directly in your JSX, and can also be passed as a prop to a child component. You can use them dynamically in your JSX code. For instance:
```
const name = ‘Josh Perez’;
const element =
ReactDOM.render(
element,
document.getElementById(‘root’)
);
```
Here, the `name` string is embedded in a JSX element using curly braces.
Please note that ReactJS XSS (Cross-site Scripting) protects from injection attacks. It means that you can safely embed user input in JSX, as it will be displayed as pure text and not as code.