33 <h2 class =" subtext" >Yearly Target: 52 Books</h2 >
44 <p class =" subtext" >Blog: <a href =" https://kavishandbooks.wordpress.com/" target =" _blank" >Kavish and Books</a ></p >
55 <BookSection
6- :year =" '2022'"
7- :bookCount =" '(' + bookNames2022.length + '/52)'"
8- :books =" bookNames2022"
6+ v-for =" (booksList, index) in books.slice().reverse()"
7+ :key =" 2017 + books.length - 1 - index"
8+ :year =" 2017 + books.length - 1 - index"
9+ :bookCount =" '(' + booksList.length + '/52)'"
10+ :books =" booksList"
911 :apiKey =" apiKey"
10- :initialShowBooks =" true "
12+ :initialShowBooks =" index == 0 "
1113 />
12- <BookSection
14+ <!-- < BookSection
1315 :year="'2021'"
1416 :bookCount="'(' + bookNames2021.length + '/52)'"
1517 :books="bookNames2021"
3840 :bookCount="'(' + bookNames2017.length + '/52)'"
3941 :books="bookNames2017"
4042 :apiKey="apiKey"
41- />
43+ /> -->
4244 </div >
4345</template >
4446
4547<script >
4648import BookSection from ' ../components/Books/BookSection.vue' ;
49+ import bookList2023 from ' ../resources/books/bookList2023.txt' ;
4750import bookList2022 from ' ../resources/books/bookList2022.txt' ;
4851import bookList2021 from ' ../resources/books/bookList2021.txt' ;
4952import bookList2020 from ' ../resources/books/bookList2020.txt' ;
@@ -58,24 +61,22 @@ export default {
5861 },
5962 data () {
6063 return {
61- bookNames2022: [],
62- bookNames2021: [],
63- bookNames2020: [],
64- bookNames2019: [],
65- bookNames2018: [],
66- bookNames2017: [],
64+ books: [],
6765 };
6866 },
6967 components: {
7068 BookSection,
7169 },
7270 mounted () {
73- this .bookNames2022 = bookList2022 .split (' \n ' );
74- this .bookNames2021 = bookList2021 .split (' \n ' );
75- this .bookNames2020 = bookList2020 .split (' \n ' );
76- this .bookNames2019 = bookList2019 .split (' \n ' );
77- this .bookNames2018 = bookList2018 .split (' \n ' );
78- this .bookNames2017 = bookList2017 .split (' \n ' );
71+ this .books = [
72+ bookList2017 .split (' \n ' ),
73+ bookList2018 .split (' \n ' ),
74+ bookList2019 .split (' \n ' ),
75+ bookList2020 .split (' \n ' ),
76+ bookList2021 .split (' \n ' ),
77+ bookList2022 .split (' \n ' ),
78+ bookList2023 .split (' \n ' ),
79+ ];
7980 },
8081};
8182 </script >
0 commit comments