P
если нету — опубликуй в npm )
Size: a a a
P
P
F
e
e
R
ES
@react-pdf/renderer, делаю по докеFont.register({ family: 'Roboto', src: 'https://fonts.googleapis.com/css2?family=Roboto:wght@100&display=swap' });
const styles = StyleSheet.create({
page: {
fontFamily: 'Roboto',
fontWeight: 'thin',
flexDirection: 'row',
backgroundColor: '#E4E4E4'
},
section: {
margin: 10,
padding: 10,
flexGrow: 1
}
});
const MyDocument = (
<Document>
<Page size="A4" style={styles.page}>
<View style={styles.section}>
<Text>Сессия #1</Text>
</View>
<View style={styles.section}>
<Text>Сессия #2</Text>
</View>
</Page>
</Document>
);
const [instance, updateInstance] = usePDF({ document: MyDocument });
return(
<a href={instance.url} download="test.pdf">
Download
</a>
);A
R
DK
OR

И
OR
И
ММ
V
.test(‘errorType’, ‘messgage, function fn(data) {
console.log(this.parent) // тут все свойства объекта;
}),DK
V