SafeView and how to use
What is SafeView?
SafeView is a component that allows you to hide sensitive information in your app visually, for presentation purposes, and more.
How to install:
npm install safeview
In order to hide an element all you need to do is to target it using the data-safe attribute.
const Component = () => {
return (
<div>
<span data-safe>
// Sensitive info
<span>
</div>
)
}
import SafeView from 'safeview';
const App = () => {
return (
<SafeView>
// Your React App
</SafeView>;
)
};
Reference:
My site is free of ads and trackers. Was this post helpful to you? Why not
Disqus is great for comments/feedback but I had no idea it came with these gaudy ads.