@@ -70,8 +70,6 @@ You will get a fully working chat application for web and mobile:
70
70
71
71
## Installation
72
72
73
- This component is only compatible with Vue ` 2.6.14 ` and above.
74
-
75
73
``` bash
76
74
# Using npm
77
75
npm install --save vue-advanced-chat
@@ -80,14 +78,7 @@ npm install --save vue-advanced-chat
80
78
yarn add vue-advanced-chat
81
79
82
80
# Using CDN
83
- < script src=" https://cdn.jsdelivr.net/npm/vue@2.6.14" ></script>
84
- < script src=" https://cdn.jsdelivr.net/npm/vue-advanced-chat@0.8.8/dist/vue-advanced-chat.min.js" ></script>
85
- ```
86
-
87
- If you want to send mp3 audio messages, you may need to install ` lamejs ` inside your project:
88
-
89
- ``` bash
90
- npm install lamejs --save
81
+ < script src=" https://cdn.jsdelivr.net/npm/vue-advanced-chat@2.0.0/dist/vue-advanced-chat.es.js" ></script>
91
82
```
92
83
93
84
[ Installation with React & Angular] ( #use-as-a-web-component-with-react-and-angular )
@@ -101,9 +92,9 @@ npm install lamejs --save
101
92
< vue- advanced- chat
102
93
ref= " chatWindow"
103
94
: current- user- id= " currentUserId"
104
- : rooms= " rooms"
105
- : messages= " messages"
106
- . room - actions= " roomActions"
95
+ : rooms= " JSON.stringify( rooms) "
96
+ : messages= " JSON.stringify( messages) "
97
+ : room- actions= " JSON.stringify( roomActions) "
107
98
/ >
108
99
< / template>
109
100
@@ -896,16 +887,6 @@ messages: {
896
887
897
888
- Follow [ Installation] ( #installation ) steps
898
889
899
- ### Install Vue.js
900
-
901
- ``` bash
902
- # Using npm
903
- npm install --save vue
904
-
905
- # Using yarn
906
- yarn add --save vue
907
- ```
908
-
909
890
### React Setup
910
891
911
892
See demo repository: https://github.com/antoine92190/vue-advanced-chat-sandbox/tree/react
@@ -914,59 +895,6 @@ See demo repository: https://github.com/antoine92190/vue-advanced-chat-sandbox/t
914
895
915
896
See demo repository: https://github.com/antoine92190/vue-advanced-chat-sandbox/tree/angular
916
897
917
- ``` jsonc
918
- // angular.json
919
-
920
- " build" : {
921
- " scripts" : [
922
- " ./node_modules/vue/dist/vue.min.js" ,
923
- " ./node_modules/vue-advanced-chat/dist/vue-advanced-chat.min.js"
924
- ]
925
- }
926
- ```
927
-
928
- ``` javascript
929
- // page.module.ts
930
-
931
- @NgModule ({
932
- ...
933
- schemas: [CUSTOM_ELEMENTS_SCHEMA ],
934
- })
935
- ```
936
-
937
- ``` html
938
- <!-- page.html -->
939
-
940
- <vue-advanced-chat
941
- height =" 100vh"
942
- [currentUserId] =" currentUserId"
943
- [roomId] =" roomId"
944
- [rooms] =" rooms"
945
- [roomsLoaded] =" true"
946
- [messages] =" messages"
947
- [messagesLoaded] =" messagesLoaded"
948
- [showFiles] =" true"
949
- [showEmojis] =" true"
950
- [showReactionEmojis] =" true"
951
- [showFooter] =" true"
952
- (fetch-messages) =" fetchMessages($event.detail[0])"
953
- (send-message) =" sendMessage($event.detail[0])"
954
- ...
955
- >
956
- </vue-advanced-chat >
957
- ```
958
-
959
- <br >
960
-
961
- ## Use in a Vue 3 project
962
-
963
- ### Install vue-advance-chat component (next branch)
964
-
965
- ``` bash
966
- # Using npm
967
- npm install --save https://github.com/antoine92190/vue-advanced-chat/tarball/next
968
- ```
969
-
970
898
<br >
971
899
972
900
## [ Contributing] ( https://github.com/antoine92190/vue-advanced-chat/blob/master/.github/CONTRIBUTING.md )
0 commit comments