Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
Drip
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
backup
Drip
Commits
2f443c77
Commit
2f443c77
authored
6 years ago
by
tina
Browse files
Options
Downloads
Patches
Plain Diff
replace require with import
parent
a43a5fd9
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
App.js
+4
-2
4 additions, 2 deletions
App.js
package-lock.json
+1802
-1802
1802 additions, 1802 deletions
package-lock.json
styles.js
+5
-2
5 additions, 2 deletions
styles.js
with
1811 additions
and
1806 deletions
App.js
+
4
−
2
View file @
2f443c77
...
@@ -6,9 +6,10 @@ import {
...
@@ -6,9 +6,10 @@ import {
TextInput
,
TextInput
,
FlatList
FlatList
}
from
'
react-native
'
}
from
'
react-native
'
console
.
log
(
'
first hi
'
)
import
*
as
styles
from
'
./styles
'
import
Datastore
from
'
react-native-local-mongodb
'
const
styles
=
require
(
'
./styles
'
)
const
Datastore
=
require
(
'
react-native-local-mongodb
'
)
const
db
=
new
Datastore
({
filename
:
'
asyncStorageKey
'
,
autoload
:
true
})
const
db
=
new
Datastore
({
filename
:
'
asyncStorageKey
'
,
autoload
:
true
})
export
default
class
drip
extends
Component
{
export
default
class
drip
extends
Component
{
...
@@ -17,6 +18,7 @@ export default class drip extends Component {
...
@@ -17,6 +18,7 @@ export default class drip extends Component {
this
.
state
=
{
this
.
state
=
{
temperatures
:
[]
temperatures
:
[]
}
}
console
.
log
(
'
hello
'
)
db
.
find
({
key
:
{
$exists
:
true
}
},
(
err
,
persistedTemperatures
)
=>
{
db
.
find
({
key
:
{
$exists
:
true
}
},
(
err
,
persistedTemperatures
)
=>
{
if
(
err
)
throw
err
if
(
err
)
throw
err
this
.
setState
({
this
.
setState
({
...
...
This diff is collapsed.
Click to expand it.
package-lock.json
+
1802
−
1802
View file @
2f443c77
Source diff could not be displayed: it is too large. Options to address this:
view the blob
.
This diff is collapsed.
Click to expand it.
styles.js
+
5
−
2
View file @
2f443c77
const
StyleSheet
=
require
(
'
react-native
'
).
StyleSheet
import
{
StyleSheet
}
from
'
react-native
'
module
.
exports
=
StyleSheet
.
create
({
const
ourStyle
=
StyleSheet
.
create
({
container
:
{
container
:
{
flex
:
1
,
flex
:
1
,
justifyContent
:
'
center
'
,
justifyContent
:
'
center
'
,
...
@@ -11,3 +12,5 @@ module.exports = StyleSheet.create({
...
@@ -11,3 +12,5 @@ module.exports = StyleSheet.create({
margin
:
10
,
margin
:
10
,
}
}
})
})
export
{
ourStyle
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment